Re: mdb2: how to save a connection in a session
| From: | Paolo Sala | Date: | Wed, 18 Feb 2009 11:45:45 +0000 |
| Subject: | Re: mdb2: how to save a connection in a session | ||
| References: | 1 | Groups: | php.pear.general |
| Request: | Send a blank email to pear-general+get-29704@lists.php.net to get a copy of this message | ||
Paolo Sala scrisse in data 30/01/2009 14:59:
> [...]
> I would like to save, in a session variable, a mdb2 connection object
It was my ignorance. There is no problem to save mdb2 connection object
in a session variable using serialize and unserialize php functions.
The problem I have is that if I create a new connection I need more than
one second to get it.
If I unserialize a previous serialized connection the time for
unserialize it is very short but is only moved to the first query:
the time to get the first query in a unserialized connection is more
than one second even if the time to execute the query is very quick.
There is a way to reduce the time to execute a query in two different
calls in different get or post request?
Thank you very much
Piviul