Bug #22986 [Ana]: Unhappily 'conection cache' handling
| From: | cmb@php.net | Date: | Wed, 24 Jun 2020 11:11:50 +0000 |
| Subject: | Bug #22986 [Ana]: Unhappily 'conection cache' handling | ||
| References: | 1 | Groups: | php.bugs |
| Request: | Send a blank email to php-bugs+get-227624@lists.php.net to get a copy of this message | ||
Edit report at https://bugs.php.net/bug.php?id=22986&edit=1
ID: 22986
Updated by: cmb@php.net
Reported by: ray at unreal64 dot net
Summary: Unhappily 'conection cache' handling
Status: Analyzed
Type: Bug
Package: ODBC related
Operating System: Windows NT4.0
PHP Version: 4.x
Block user comment: N
Private report: N
New Comment:
I agree that trying to re-use a persistent connection even though
odbc_connect() is called is more like a bug. However, changing
that in a stable PHP version may cause a BC break (some setups may
rely on the behavior).
Furthermore, persistent ODBC connections may not be the best idea
at all, if the system supports ODBC connection pooling; a
respective note for PDO ODBC[1] also applies to ext/odbc.
[1] <https://www.php.net/manual/en/pdo.connections.php>
Previous Comments:
------------------------------------------------------------------------
[2017-10-24 02:21:12] kalle@php.net
I would argue that this is more a bug, gonna re-classify it as such as by looking at the code of
ext/odbc it still seems to be present today
------------------------------------------------------------------------
[2003-05-18 22:31:01] kalowsky@php.net
Updating the verison since this effects ALL PHP4 installations. Hopefully this won't be the
case with 5 if I can get things done :)
------------------------------------------------------------------------
[2003-05-18 22:30:15] kalowsky@php.net
Yes yes, this is on my TODO list. In fact it's kind of working already, I just haven't
commited any code. Moving this from a bug to a feature request, because it's not really a bug.
You are correct though that you can change the password/user to get around this, but an even easier
solution is to change the cursor type.
------------------------------------------------------------------------
[2003-04-24 01:16:59] ray at unreal64 dot net
I didn't try binaries, but I looked on current sources and checked changes on ODBC files.
I didn't find anything in php_odbc.c (odbc_do_connect) which solves cache problem. I expected
adding connection 'flag' or 'odbc_connect_nocache' or something.
Still there is 'connection' handling which setups hash array and ALWAYS search array and
reuse connections. It causes problems with transactions and more physical connections.
Let me know, if I missed something :)
R.
------------------------------------------------------------------------
[2003-03-31 11:57:46] why at email dot address dot com
Pgsql solves this trouble by 'connection flags' and PGSQL_CONNECT_FORCE_NEW.
------------------------------------------------------------------------
The remainder of the comments for this report are too long. To view
the rest of the comments, please view the bug report online at
https://bugs.php.net/bug.php?id=22986
--
Edit this bug report at https://bugs.php.net/bug.php?id=22986&edit=1