Subject: | Related to #1960 |
Date: | Thu, 9 Jul 2009 16:55:10 -0400 |
To: | bug-DBD-mysql [...] rt.cpan.org |
From: | Gregory Krohne <krohne [...] gmail.com> |
perl v5.8.4 for MSWin32-x86-multi-thread
DBD:mysql v2.1026
This seemingly innocent line of code throws a syntax error.
7903 $sql =<<EOSQL;
7904 UPDATE myTable SET PrimaryID = '$ter{$keyname}'
7905 WHERE PrimaryID = $pid
7906 AND RequestID = '$ter{'RequestID'}'
7907 EOSQL
7908 $rv = $Dbh->do($sql);
The error:
DBD::mysql::db do failed: You have an error in your SQL syntax. Check
the manual that corresponds to your MySQL server version for the right
syntax to use near 'AND RequestID = '927'' at line 3 at ../lib/Fwmi.pm
line 7908.
The PrimaryID and RequestID columns are integers, of course. The
'$ter{$keyname}' and '$ter{'RequestID'}' expressions are used in a
SELECT statement immediately preceding these lines, without incident.
This seems related to bug #1960, but that bug was fixed in v2.1024. Is
it a bug? If not, what else might I try?
Regards,
Greg Krohne