in reply to Re^2: DBI::SQLite slowness
in thread DBI::SQLite slowness
If I simply have "$dbh->commit" following the For loop, is that effectively the same as explicitly using transactions?
No; BEGIN WORK (or BEGIN TRANSACTION or just plain BEGIN) starts a transaction in SQL. Then (normally after 1 or more insert/delete/update's) COMMIT commits the transaction (or, when an error occurs, ROLLBACK rolls the transaction back to the state just before the BEGIN).
See DBI's begin_work
(I don't use SQLite; in the above I am assuming SQLite does this the same way that other (RDBMS) databases do)
|
---|
Replies are listed 'Best First'. | |
---|---|
Re^4: DBI::SQLite slowness
by Endless (Beadle) on Sep 21, 2013 at 18:20 UTC | |
by erix (Prior) on Sep 22, 2013 at 05:12 UTC |
In Section
Seekers of Perl Wisdom