note 48592 deleted from function.mysql-close by betz
| From: | betz@php.net | Date: | Wed, 05 Oct 2005 10:41:02 +0000 |
| Subject: | note 48592 deleted from function.mysql-close by betz | ||
| References: | 1 | Groups: | php.notes |
| Request: | Send a blank email to php-notes+get-96413@lists.php.net to get a copy of this message | ||
Note Submitter: red at redworld dot ru
----
The mysql_close() call does seem to behave strangely when I make use of a nested call to a function
that also connects to the database.
I am iterating through some results to a select, and with each row of the results I'm executing
a separate function. This function also talks to the database and at the end of the parent iteration
I get an error with the mysql_close() call. It seems to me that this is something in the region of
issues with variable localisation.
It seems that MySQL doesn't mind if you don't close the link. This smells a little
dangerous to me but when I removed the mysql_close() call at the end of the parent loop all worked.
Me thinks that things should not really be like this. I'm a child of perl ... there must be a
way to open and close database connections without running into issues with multiple concurrent
connections.