RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Scott T. Hildreth
001 3:04 PM > To: Doug > Cc: [EMAIL PROTECTED]; Rick Osterberg > Subject: RE: Strange CHAR/Oracle/DBI issue > > > > like would work, but it will match '123456' as well as '12345 '. > > On 12-Jun-01 Scott T. Hildreth wrote: >> >> DBD::Oracle tr

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Wilson, Doug
To: Doug Cc: [EMAIL PROTECTED]; Rick Osterberg Subject: RE: Strange CHAR/Oracle/DBI issue like would work, but it will match '123456' as well as '12345 '. On 12-Jun-01 Scott T. Hildreth wrote: > > DBD::Oracle trims the trailing spaces by default. > try this

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Scott T. Hildreth
DBD::Oracle trims the trailing spaces by default. try this select * from bar where bar = rpad(?, 8). or use DBI; use DBD::Oracle qw(:ora_types); my $dbh = DBI->connect( "dbi:Oracle:", "user/passwd", "", {RaiseError => 1} ) or die $DBI::errstr; $dbh->{ora_ph_type} = 9

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Scott T. Hildreth
like would work, but it will match '123456' as well as '12345 '. On 12-Jun-01 Scott T. Hildreth wrote: > > DBD::Oracle trims the trailing spaces by default. > try this select * from bar where bar = rpad(?, 8). > > or > > use DBI; > use DBD::Oracle qw(:ora_types); > > my $dbh = DBI->connect(

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Wilson, Doug
Just curious if it would work if you change '= ?' to 'like ?' and value to '12345%' ??? -Original Message- From: Rick Osterberg [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 12, 2001 2:23 PM To: Wilson, Doug Cc: '[EMAIL PROTECTED]' Subject:

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Rick Osterberg
Nope -- doesn't work either. (I had neglected to mention... we had tried that, too.) -Rick On Tue, 12 Jun 2001, Wilson, Doug wrote: > Maybe it is binding as a number. Try: > $sth->bind_param(1, $value, { TYPE => SQL_CHAR }); > before the execute instead of putting $value in the execute; > > --

RE: Strange CHAR/Oracle/DBI issue

2001-06-12 Thread Wilson, Doug
Maybe it is binding as a number. Try: $sth->bind_param(1, $value, { TYPE => SQL_CHAR }); before the execute instead of putting $value in the execute; -Original Message- From: Rick Osterberg [mailto:[EMAIL PROTECTED]] Sent: Tuesday, June 12, 2001 2:04 PM To: '[EMAIL PROTECTED]' Subject: St