in reply to weird DBI error re: parameter binding
But it seems that DBI (or the ODBC driver) doesn't like that line. First off, a field name of "Today's Date" is god-awful ... i don't use spaces or any special characters in my tables or my fields, regardless of whether or not it is valid to do so. It most definitely is not portable. Why not name that field today_date or such? Much easier to deal with.WHERE ((x Is Not Null) AND ([Today's Date]> ?))
My recommendation is to simplify your test, maybe something like:
And see what happens. If that doesn't reveal anything new, then how about simply:my $dbh = ( 'connection string', 'user', 'pass', {RaiseError => 1}, # IMPORTANT!!! ); my $sth = $dbh->prepare(q| select * from Referrals where [Today's Date] > ? |); $sth->execute($date);
UPDATE:my $sth = $dbh->prepare(q| select [Today's Date] from Referrals |); $sth->execute();
jeffa
L-LL-L--L-LL-L--L-LL-L-- -R--R-RR-R--R-RR-R--R-RR B--B--B--B--B--B--B--B-- H---H---H---H---H---H--- (the triplet paradiddle with high-hat)
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: (jeffa) Re: weird DBI error re: parameter binding
by Grygonos (Chaplain) on Jul 30, 2003 at 17:17 UTC | |
by tye (Sage) on Jul 30, 2003 at 17:50 UTC | |
by Grygonos (Chaplain) on Jul 30, 2003 at 19:14 UTC | |
by tye (Sage) on Jul 30, 2003 at 19:21 UTC | |
by Grygonos (Chaplain) on Jul 30, 2003 at 19:55 UTC |