LHowell has asked for the wisdom of the Perl Monks concerning the following question:
The script dies with the following on the command line:$InsertIntoMetar = <<SQL; REPLACE INTO Metar SELECT *,NULL FROM Deduped_Metars_No_Errors a; SQL .............. $sth = $dbh->prepare($InsertIntoMetar) or die "Can't prepare $InsertIntoMetar: $dbh->errstr\n"; $rv = $sth->execute + ##Insert into production Metar table. or die "can't execute the query: $sth->errstr";
The interesting thing is that I can cut and paste the SQL contained in the prepare portion of the $LoadIntoMetar into a SQLYog window and it executes just fine!! Thoughts Anyone?can't execute the query: DBI:: st=HASH(0x1a07924)-> errstr at Load_Met +ar_New1.pl line 600. Line 600 is the line that contains the $rv = $ +sth->execute shown above.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Strange Execute Issue from PERL
by Corion (Patriarch) on May 07, 2011 at 14:01 UTC | |
by LHowell (Initiate) on May 07, 2011 at 21:27 UTC | |
by Corion (Patriarch) on May 07, 2011 at 21:37 UTC | |
by LHowell (Initiate) on May 07, 2011 at 23:33 UTC | |
by Corion (Patriarch) on May 08, 2011 at 06:53 UTC | |
|