Re: Obtaining a total number of records in a cursor (Count)

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Michael Dunn <michael(at)2cactus(dot)com>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: Obtaining a total number of records in a cursor (Count)
Date: 2001-04-04 04:37:44
Message-ID: 262.986359064@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Michael Dunn <michael(at)2cactus(dot)com> writes:
> is there a command, temporary table, or session in memory that I can
> obtain a total count of records for that cursor?

Not short of reading out the tuples ... in general there is no way to
predict the number of tuples that a query will return, except by
computing them.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Steve Jorgensen 2001-04-04 04:49:49 Windows install
Previous Message Michael Dunn 2001-04-04 01:41:04 Obtaining a total number of records in a cursor (Count)