The pg_prepared_statments view will give you information on prepared statments currently resident in the database backend. I suggest you run your progam (with a couple of "Enter to continue" breakpoints in the code) and, in another session, select from pg_prepared_statements and see if the prepared statement is still there.
I'll be trying this myself a bit later once I stabilise my system, so watch this space!
My system is stabilised and I'm looking at this now. I'm not getting a lot from pg_prepared_statements yet: perhaps this view only reports on statements you've prepared using PostgreSQL's PREPARE through their SQL interface, and not DBI's DBD::Pg $dbh->prepare(). I know that a few versions back PostgreSQL's DBD driver didn't support prepared statements (the operation was still there, it just wasn't doing the whole magic), I imagine that it does today but will investigate further. Cheers, Stuart. ---------------------------(end of broadcast)--------------------------- TIP 3: Have you checked our extensive FAQ? http://www.postgresql.org/docs/faq