The usefulness of this seems pretty dubious.  You aren't going to have a
bunch of random bits of code sharing a connection; it's going to be a
single application that probably knows perfectly well exactly which
queries it needs prepared.  So I don't think the stats will pay for

Not true. Personally, I was looking for something like this, before I decided to go with stored sql procs instead.

The problem is a website that uses persistent connections.

Say we have a query that takes 350ms to get threads in a forum, and half of that is planning time. Any particular PHP process does not know if a previous process has already prepared that query or not. So I have to prepare it every time, deal with errors, etc.

However, I now use sql stored procs as basically 'cached prepared queries', so it's no longer a problem for me.


---------------------------(end of broadcast)---------------------------
TIP 6: Have you searched our list archives?

Reply via email to