Re: Prepared statements and generic plans - Mailing list pgsql-hackers

From Albe Laurenz
Subject Re: Prepared statements and generic plans
Date
Msg-id A737B7A37273E048B164557ADEF4A58B5385A505@ntex2010i.host.magwien.gv.at
Whole thread Raw
In response to Re: Prepared statements and generic plans  ('Bruce Momjian *EXTERN*' <bruce@momjian.us>)
Responses Re: Prepared statements and generic plans  ("'bruce@momjian.us'" <bruce@momjian.us>)
List pgsql-hackers
Bruce Momjian wrote:
>> !    distinct column values, a generic plan assumes a column equality
>> !    comparison will match 33% of processed rows.  Column statistics
>>
>> ... assumes *that* a column equality comparison will match 33% of *the* processed rows.
> 
> Uh, that seems overly wordy.  I think the rule is that if the sentence
> makes sense without the words, you should not use them, but it is
> clearly a judgement call in this case.  Do you agree?

My gut feeling is that at least the "the" should be retained, but mine
are the guts of a German speaker.
It is clearly a judgement call, so follow your instincts.

> Updated patch attached.
> 
> One more thing --- there was talk of moving some of this into chapter
> 66, but as someone already mentioned, there are no subsections there
> because it is a dedicated topic:
> 
>     66. How the Planner Uses Statistics.
> 
> I am not inclined to add a prepare-only section to that chapter.  On the
> other hand, the issues described apply to PREPARE and to protocol-level
> prepare, so having it in PREPARE also seems illogical.  However, I am
> inclined to leave it in PREPARE until we are ready to move all of this
> to chapter 66.

I think it would be ok to leave it where it is in your patch; while the
paragraph goes into technical detail, it is still alright in the general
documentation (but only just).

Yours,
Laurenz Albe

pgsql-hackers by date:

Previous
From: Michael Paquier
Date:
Subject: Re: [sqlsmith] Failed assertion in postgres_fdw/deparse.c:1116
Next
From: Kyotaro HORIGUCHI
Date:
Subject: Re: Improve tab completion for USER MAPPING