mysql_pconnect problems in php3 and 4

From: Date: Wed, 27 Sep 2000 00:09:13 +0000
Subject: mysql_pconnect problems in php3 and 4
Groups: php.db 
Request: Send a blank email to php-db+get-3104@lists.php.net to get a copy of this message
Hi, I'm trying to maintain a persistant connection to the db so that I can use a temporary table to store user information, in this case, search results. However, I can't seem to get the connection to last between one script and the second. The first script opens the pconnection, selects the db, and then uses a <a href> </a> to link to the second page and passes the temporary table name. The second script should query the table, without needing to open another connection or selecting the db again, right?! When I do add a pconnect to the second script the persistant connection is reset and the temporary table lost. here's script 1: include("../boats.inc"); pconnect_boats(); // these are both in the include select_boats(); $date = getdate(); $list_table = "list_$date[minutes]_$date[seconds]"; print($list_table); $query = "CREATE TEMPORARY TABLE $list_table (boat_id INT)"; $result = mysql_query($query); print("<a href=persist2.php?list_table=$list_table> click here to go to persist2 </a>"); and script 2: include("../boats.inc"); print($list_table); $result = query_all(boat_id,$list_table); ...and then it would do something with the $result Thanks Kepa

« previous php.db (#3104) next »