Beefy Boxes and Bandwidth Generously Provided by pair Networks
Pathologically Eclectic Rubbish Lister
 
PerlMonks  

Re: LOCK TABLES using Perl in MySQL

by greywolf (Priest)
on Oct 13, 2001 at 01:29 UTC ( [id://118577]=note: print w/replies, xml ) Need Help??


in reply to LOCK TABLES using Perl in MySQL

Here is something that should work.
$sth = $dbh->prepare("LOCK TABLES tablename WRITE"); unless ($sth->execute()) { die $dbh->errstr() } #sql queries here $sth = $dbh->prepare("UNLOCK TABLES"); unless ($sth->execute()) { die $dbh->errstr() }

mr greywolf

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others perusing the Monastery: (3)
As of 2024-04-25 17:31 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found