php.net |  support |  documentation |  report a bug |  advanced search |  search howto |  statistics |  random bug |  login
Bug #17126 mysql_pconnect() and mysql_query("LOCK TABLES...")
Submitted: 2002-05-09 15:08 UTC Modified: 2002-05-10 04:41 UTC
From: stian at nixia dot no Assigned:
Status: Closed Package: MySQL related
PHP Version: 4.0CVS-2002-05-09 OS: RedHat Linux 7.2 with updates
Private report: No CVE-ID: None
Welcome back! If you're the original bug submitter, here's where you can edit the bug or add additional notes.
If you forgot your password, you can retrieve your password here.
Password:
Status:
Package:
Bug Type:
Summary:
From: stian at nixia dot no
New email:
PHP Version: OS:

 

 [2002-05-09 15:08 UTC] stian at nixia dot no
This is a test-thing from one of my projects. The problem is the LOCK TABLES not beeing unlocked again.. This is a userproblem, but can sometimes be hard to track when you rerun the script, and hit another Apache-PID and tables still beeing locked.. maybe when a Link identifier is destroyed, or new database is selected, an "UNLOCK TABLES" should be ommited?

testsource from project:

<?
unset ( $ROOT ); $ROOT = "../";
include_once ( $ROOT."include/setup.php" ); 
include_once ( $INCLUDE."mysql.php" );

MySQL_DoConnect();
echo "Locking..."; 
mysql_query("LOCK TABLES Ansatt WRITE;");
echo "Done (".mysql_error().")<br>";
?>

Patches

Pull Requests

History

AllCommentsChangesGit/SVN commitsRelated reports
 [2002-05-10 04:41 UTC] sander@php.net
PHP is not the appropriate place to do this. If you want auto-unlocking, bug the MySQL-people or learn to write proper code.
 
PHP Copyright © 2001-2025 The PHP Group
All rights reserved.
Last updated: Mon Jun 30 07:02:47 2025 UTC