in reply to Handling a Database Error
my $q = 'INSERT INTO some_table (data) VALUES (?)'; my $sth = $dbh->prepare($q); while(my $data = $csv->get_next_line()) { eval{ $sth->execute($data); } if($@) { next; } # More code here... }
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: Handling a Database Error
by dragonchild (Archbishop) on Sep 30, 2005 at 18:01 UTC | |
|
Re^2: Handling a Database Error
by k_rajesh (Sexton) on Sep 30, 2005 at 19:57 UTC | |
|
Re^2: Handling a Database Error
by pg (Canon) on Sep 30, 2005 at 20:14 UTC |