Bart Kelsey wrote:
Reidy, Ron wrote:
>From your first post -
Is your data wrapped in " chars?
No. The line that the program is choking on (which is the first line
in the data file), looks like this:
critical|SEVERITY|1|Critical|informix|11/03/2000|
I've reduced the error to this block of code:
open(IN, "<abbrev.dat");
my $line = <IN>;
chomp($line);
my(@data) = split(/\|/, $line);
my($sth) = $dbh->prepare("insert into foo (bar) values (to_date(?,
'MM/DD/YYYY'))");
$sth->execute($data[5]);
Interestingly, when I set $data[5] manually inside the perl script, it
seems to work fine. Could this be some sort of weird character encoding
problem?