Robert Haas <robertmhaas(at)gmail(dot)com> writes:
> It knows that queries beginning with "select" or "values" are select
> commands, but it seems not to be clued in about "table" and "with".
What we really ought to do IMO is throw out the entire current
implementation of fetch_count. If libpq exposed access to the
protocol-level fetch count, we could implement it without this
cursor kluge.
regards, tom lane