Re: lock tables problem

From: Date: Tue, 08 Aug 2000 19:35:43 +0000
Subject: Re: lock tables problem
References: 1  Groups: php.general 
Request: Send a blank email to php-general+get-10771@lists.php.net to get a copy of this message
I dont quite follow you, but you shoudnl't need to lock the tables selecting inserting and updating... can you give me some more example code? of inserting.php and the form? On Wed, 9 Aug 2000, Mark Lo wrote: > but the action page like <form method="post" action="inserting.php"> > ....this action pages require the information display in the first page > without being updated or deleted or inserted. > > > ----- Original Message ----- > From: Chris Murley <murley@appindex.net> > To: Mark Lo <markloky@netvigator.com> > Cc: php general <php-general@lists.php.net>; <mysql@lists.mysql.com> > Sent: Wednesday, August 09, 2000 3:28 AM > Subject: Re: [PHP] lock tables problem > > > > You shouldnt have to, mysql will automagically lock and unlock them when > > doing an insert/update. > > > > > > > > On Wed, 9 Aug 2000, Mark Lo wrote: > > > > > Hi, > > > > > > I need to lock the tables because I need inserting and updating > later. > > > > > > like ....<form action="inserting.php" method="post">...i > > > will do the > > > insserting once i hit the submit button.... > > > > > > Any Ideas of how to lock a specific table. > > > > > > Thank You > > > > > > Mark > > > > > > > > > ----- Original Message ----- > > > From: Chris Murley <murley@appindex.net> > > > To: Mark Lo <markloky@netvigator.com> > > > Cc: php general <php-general@lists.php.net>; <mysql@lists.mysql.com> > > > Sent: Wednesday, August 09, 2000 3:22 AM > > > Subject: Re: [PHP] lock tables problem > > > > > > > > > > Why would you need to lock the table to do a select? > > > > > > > > > > > > mysql usually only locks when inserting/updateing? > > > > > > > > > > > > > > > > On Wed, 9 Aug 2000, Mark Lo wrote: > > > > > > > > > Hi, > > > > > > > > > > my script is as follows (once I lock the table1, i won't be able > to > > > read table2) > > > > > what is the problems; > > > > > > > > > > require("Password.hlh"); > > > > > mysql_select_db("database1"); > > > > > mysql_query("lock tables table1 read"); > > > > > $query="select * from table1"; > > > > > > > > > > > > > > > then---the problem starts here... > > > > > > > > > > require("Password.hlh"); > > > > > mysql_select_db("database1"); > > > > > mysql_query("lock tables table2 read"); > > > > > $query="select * from table2"; > > > > > > > > > > ---unable to select from table2--- > > > > > > > > > > Can anyone please point me out the problems. > > > > > > > > > > Thank you so much > > > > > > > > > > Mark > > > > > > > > > > > > > > > > > > > > > > -- > > 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 (#10771) next »