in reply to How to make my DBD::CSV DB code faster.
And rest off your code should work unchanged, and will be much faster because it's reading from RAM instead of disk.use DBI; #my $dbh = DBI->connect("DBI:CSV:f_dir=.;csv_eol=\n;") or die "Cannot +connect: " . $DBI::errstr; #$dbh->{'csv_tables'}->{'bt'} = { 'file' => './X_Con.csv'}; #$dbh->{'csv_tables'}->{'sec'} = { 'file' => './Y_Con.csv'}; #$dbh->{'csv_tables'}->{'stats'} = { 'file' => './Z_Con.csv'}; my $dbh = DBI->connect('dbi:AnyData(RaiseError=>1):'); $dbh->func( 'bt', 'CSV', './X_Con.csv', 'ad_import'); $dbh->func( 'sec', 'CSV', './Y_Con.csv', 'ad_import'); $dbh->func( 'stats', 'CSV', './Z_Con.csv', 'ad_import');
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re^2: How to make my DBD::CSV DB code faster.
by jZed (Prior) on Sep 30, 2005 at 02:39 UTC |