Since we talking about bind, I'm have a fun time with it talking to
an AS/400 DB2 via IBM's iSeries ODBC driver and DBD::ODBC on linux.
Seems like any error kills the database connection and eval does
not help. Does ODBC have a much harder time figuring out what to
do with field types? I'm having to do this sort of thing:
$i=1;
$sth->bind_param($i++,'CADDR1',{TYPE=>SQL_VARCHAR}); #'CHAR(30)'
$sth->bind_param($i++,'CADDR2',{TYPE=>SQL_VARCHAR}); #CHAR(30)'
$sth->bind_param($i++,'CAUTH#',{TYPE=>SQL_VARCHAR}); #CHAR(6)'
$sth->bind_param($i++,'CCARD#',{TYPE=>SQL_NUMERIC}); #NUMERIC(19)'
Spelling it out to the last detail seems to help.
Hell, I'm just trying to $DB->do(INSERT...) sql statements that work
from dbish on command line, same drivers, same machine, same sequence.
DB->trace() suggests that DBD::ODBC is looking for a cached table
description which might make it easier. I'm thinking maybe
SELECT * LIMIT 1 might give it that.... oops, no LIMIT 1 on AS400
DB/2. Maybe SELECT * WHERE key='does_not_exist' will work. Perhaps
dbish has those table descriptions where a vanilla tightly scoped
$sth might not?
I'll get there eventually, but if anyone has any experience to share
with the oddities of this setup (me coming from UNIX background) I'd
much appreciate it. It seems like it should not be this hard.
cfm
--
Christopher F. Miller, Publisher [EMAIL PROTECTED]
MaineStreet Communications, Inc 208 Portland Road, Gray, ME 04039
1.207.657.5078 http://www.maine.com/
Content/site management, online commerce, internet integration, Debian linux