Fancy Database Stuff

Variable bindings for repeated statements

$sth = $dbh->("insert into table(foo,bar,baz) values (?,?,?)");

while(<>) {

chop;

my ($foo,$bar,$baz) = split /,/;

$sth->($foo,$bar,$baz);

}

Previous slide Next slide Back to first slide View graphic version