Beefy Boxes and Bandwidth Generously Provided by pair Networks
Clear questions and runnable code
get the best and fastest answer

Re: load data to MySQL database using Perl

by ccn (Vicar)
on Oct 01, 2009 at 05:47 UTC ( #798526=note: print w/ replies, xml ) Need Help??

in reply to load data to MySQL database using Perl

Set AutoCommit => 1 or call $dbh->commit; before disconnect.

See perldoc DBI about commiting

Comment on Re: load data to MySQL database using Perl
Select or Download Code
Replies are listed 'Best First'.
Re^2: load data to MySQL database using Perl
by xieyulong (Initiate) on Oct 02, 2009 at 14:31 UTC

    Yes. Thanks a lot. When I set autocommit from "off" to "on", it worked as expected.

    I checked perldoc DBI about the setting of autocommit when establishing a connection, but did not understand well. In practice in which situation the autocommit should be set to "off" and then call commit to make the transaction take effect.

    Thanks again.

Log In?

What's my password?
Create A New User
Node Status?
node history
Node Type: note [id://798526]
and the web crawler heard nothing...

How do I use this? | Other CB clients
Other Users?
Others scrutinizing the Monastery: (5)
As of 2016-02-14 17:27 GMT
Find Nodes?
    Voting Booth?

    How many photographs, souvenirs, artworks, trophies or other decorative objects are displayed in your home?

    Results (470 votes), past polls