Re: Parsing speed (was Re: pgstats_initstats() cost) - Mailing list pgsql-hackers

From Tom Lane
Subject Re: Parsing speed (was Re: pgstats_initstats() cost)
Date
Msg-id 23741.1060785134@sss.pgh.pa.us
Whole thread Raw
In response to Re: Parsing speed (was Re: pgstats_initstats() cost)  (Christopher Kings-Lynne <chriskl@familyhealth.com.au>)
Responses Re: Parsing speed (was Re: pgstats_initstats() cost)
List pgsql-hackers
Christopher Kings-Lynne <chriskl@familyhealth.com.au> writes:
> What do you actually get back from a Parse request?

Nothing.  If successful, it creates a prepared statement inside the
server.

It might possibly make sense for a libpq routine that exposes Parse
to actually do Parse followed by Describe Statement; that would allow
it to give back (a) an indication of the number and types of parameters
needed by the statement, and (b) an indication of the column set to be
returned, if it's a SELECT.  However, the protocol doesn't tell anything
about the type of a non-SELECT statement.  In any case, this would
require more invention and coding than I care to do at this point in
the release cycle (since there's no support in the guts of libpq for
accepting ParameterDescription messages from the backend).  If that's
what we think we want, we'd better put it on the wish-list for 7.5.
        regards, tom lane


pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: set constraints docs page
Next
From: Stephan Szabo
Date:
Subject: Re: set constraints docs page