Skip site navigation (1) Skip section navigation (2)

Re: Changing the result of ExecutorRun

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Gregory Stark <stark(at)enterprisedb(dot)com>
Cc: pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: Changing the result of ExecutorRun
Date: 2008-10-31 17:37:11
Message-ID: 6160.1225474631@sss.pgh.pa.us (view raw or flat)
Thread:
Lists: pgsql-hackers
Gregory Stark <stark(at)enterprisedb(dot)com> writes:
> Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us> writes:
>> * Return the count of tuples processed, probably as a long since that's
>> what the input limit-count is.  There are potential overflow issues with
>> this definition on 32-bit machines, though that's not going to affect
>> functions.c since it passes a limit of 1 tuple in the cases where it
>> needs to examine the result, and no one else presently cares at all.
>> But the possibility of overflow might limit the usefulness of this
>> definition in other scenarios.

> And what would that mean for a cursor which was read forward and backward?

Nothing really; the cursor code does its own counting.

Hmm ... now that I look at it, there is already a counter
estate->es_processed, so there's really no reason for ExecutorRun to
return anything at all.

es_processed is only uint32, so someday we might want to widen it, but
I think it's not important in current usage.  In any case that'd be
orthogonal to this discussion.

			regards, tom lane

In response to

pgsql-hackers by date

Next:From: Kevin GrittnerDate: 2008-10-31 17:39:50
Subject: Re: Enabling archive_mode without restart
Previous:From: Robert HaasDate: 2008-10-31 17:37:00
Subject: Re: pre-MED

Privacy Policy | About PostgreSQL
Copyright © 1996-2014 The PostgreSQL Global Development Group