Re: Re: lock table problems

From: Date: Wed, 09 Aug 2000 00:55:27 +0000
Subject: Re: Re: lock table problems
Groups: php.general 
Request: Send a blank email to php-general+get-10811@lists.php.net to get a copy of this message
Is the need for locking the tables like this going to be eliminated when MySql starts supporting transactions? ---------- >From: "Gerald L. Clark" <gerald_clark@suppliersystems.com> >To: Mark Lo <markloky@netvigator.com> >Cc: php general <php-general@lists.php.net>, mysql@lists.mysql.com >Subject: [PHP] Re: lock table problems >Date: Tue, Aug 8, 2000, 4:06 PM > > Mark Lo wrote: >> >> Hi, >> >> when I exec the script like mysql_query("lock tables table_name read"); >> this script locks all of the tables under the same database. Can anyone > point me out please!!! >> >> Thank You so much >> >> Mark > No it does not. > It only locks the tables you tell it to lock. > You can only access tables you locked until you unlock the tables. > This prevents deadlocks. > If you intend to access table2 while table1 is locked, you must lock > them both > "lock tables table1 read, table2 read" > > Please read the manual! > > -- > PHP General Mailing List (http://www.php.net/) > To unsubscribe, e-mail: php-general-unsubscribe@lists.php.net > For additional commands, e-mail: php-general-help@lists.php.net > To contact the list administrators, e-mail: php-list-admin@lists.php.net

« previous php.general (#10811) next »