On 10.05.2017 19:11, Konstantin Knizhnik wrote:
>
> Based on the Robert's feedback and Tom's proposal I have implemented
> two new versions of autoprepare patch.
>
> First version is just refactoring of my original implementation: I
> have extracted common code into prepare_cached_plan and
> exec_prepared_plan
> function to avoid code duplication. Also I rewrote assignment of
> values to parameters. Now types of parameters are inferred from types
> of literals, so there may be several
> prepared plans which are different only by types of parameters. Due to
> the problem with type coercion for parameters, I have to catch errors
> in parse_analyze_varparams.
>
Attached please find rebased version of the autoprepare patch based on
Tom's proposal (perform analyze for tree with constant literals and then
replace them with parameters).
Also I submitted this patch for the Autum commitfest.
--
Konstantin Knizhnik
Postgres Professional: http://www.postgrespro.com
The Russian Postgres Company
--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers