Re: MOVE doesn't return number of rows

From: Tom Lane <tgl(at)sss(dot)pgh(dot)pa(dot)us>
To: Phil Endecott <spam_from_postgresql_general(at)chezphil(dot)org>
Cc: pgsql-general(at)postgresql(dot)org
Subject: Re: MOVE doesn't return number of rows
Date: 2004-09-09 16:28:08
Message-ID: 6567.1094747288@sss.pgh.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Phil Endecott <spam_from_postgresql_general(at)chezphil(dot)org> writes:
> According to the documentation for MOVE, it returns the number of rows
> that it has moved over.

That's a documentation bug. CVS tip has the correct explanation:

The count is the number of rows that a FETCH command with the same
parameters would have returned (possibly zero).

> What I'm actually trying to do is to find the number of rows in the
> query result. I was hoping to be able to do a "MOVE ABSOLUTE -1" to get
> this. Any other suggestions?

MOVE FORWARD ALL.

regards, tom lane

In response to

Browse pgsql-general by date

  From Date Subject
Next Message Frank Finner 2004-09-09 17:13:39 Re: Upgrading PostgreSQL 7.1.3
Previous Message Bruce Momjian 2004-09-09 16:07:45 Re: How to determine a database is intact?