| From: | Marko Tiikkaja <marko(at)joh(dot)to> | 
|---|---|
| To: | Vladimir Sitnikov <sitnikov(dot)vladimir(at)gmail(dot)com> | 
| Cc: | Pavel Stehule <pavel(dot)stehule(at)gmail(dot)com>, Albe Laurenz <laurenz(dot)albe(at)wien(dot)gv(dot)at>, PostgreSQL-development <pgsql-hackers(at)postgresql(dot)org>, Dave Cramer <pg(at)fastcrypt(dot)com> | 
| Subject: | Re: Fwd: [JDBC] Re: 9.4-1207 behaves differently with server side prepared statements compared to 9.2-1102 | 
| Date: | 2016-01-13 13:47:37 | 
| Message-ID: | 56965579.1020909@joh.to | 
| Views: | Whole Thread | Raw Message | Download mbox | Resend email | 
| Thread: | |
| Lists: | pgsql-hackers pgsql-jdbc | 
On 13/01/16 14:36, Vladimir Sitnikov wrote:
>> Say you already have a plan which looks like this:
>> Now the plan gets invoked with  $1 = 5.  What exactly in your mind would happen here?
>
> A sequential scan with $1=5 condition. What else could be there?
I don't know, it's your proposal :-) But it looks like I misunderstood.
> Note: I do not suggest changing already cached plans yet.
> I suggest looking into "6th bind values" when building a cached plan.
But that wouldn't have helped your case.  The custom plan is *more 
expensive*; I'm guessing because the generic plan gambles on a better 
average case instead of preparing for the worst case.
.m
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Anastasia Lubennikova | 2016-01-13 13:58:32 | Re: WIP: Covering + unique indexes. | 
| Previous Message | Fabien COELHO | 2016-01-13 13:37:27 | Re: pgbench stats per script & other stuff | 
| From | Date | Subject | |
|---|---|---|---|
| Next Message | Vladimir Sitnikov | 2016-01-13 14:02:27 | Re: Fwd: [JDBC] Re: 9.4-1207 behaves differently with server side prepared statements compared to 9.2-1102 | 
| Previous Message | Vladimir Sitnikov | 2016-01-13 13:36:06 | Re: Fwd: [JDBC] Re: 9.4-1207 behaves differently with server side prepared statements compared to 9.2-1102 |