From: mikeo <mikeo@spectrumtelecorp.com>
To: Cary O'Brien <cobrien@Radix.Net>
To: pgsql-general@hub.org
Subject: Re: Re: [SQL] oracle rownum equivalent?
Date: Thu, 08 Jun 2000 08:20:10 -0400
Message-ID: <3.0.1.32.20000608082010.0092bdb0@pop.spectrumtelecorp.com> (raw)
In-Reply-To: <200006072247.SAA03722@saltmine.radix.net>
References: <3.0.1.32.20000607101423.00930360@pop.spectrumtelecorp.com>
At 06:47 PM 6/7/00 -0400, Cary O'Brien wrote:
>
>> thanks for the response. oid is equivalent to oracle rowid.
>
>I think there is a fundamentel difference between oid and rownum.
>Oid is just a serial number. Rownum is a long string that tells
>oracle where exactly the row is. So *I think* rownum can be
>used for fast lookups, where oid, unless indexed, can't.
>
>Other than that they are the same pretty much.
>
>-- cary
>
i'll have to respectfully disagree with you on your interpretation of
rownum.
in oracle, rownum tells only the relative position of a row in a result set.
also, it is an integer value starting at 1 up to nrows retrieved and is used,
for the most part, to limit the result set and not for fast lookups. it also
can be used in a DML statement within a function, such as mod(), to aid in
generating a value. the point here is moot though, as postgres doesn't have
an equivalent and i'll have to learn to live without that small piece of
oracle and enjoy what i see as the greater benefits of postgres.
:) mikeo
Reply instructions:
You may reply publicly to this message via plain-text email
using any one of the following methods:
* Reply to all the recipients from your mail client; the link fills in
the headers below: reply via email
Some clients, webmail especially, drop In-Reply-To and References from
a link, and the reply then starts a new thread: use the mbox below.
To: pgsql-sql@postgresql.org
Cc: mikeo@spectrumtelecorp.com, cobrien@Radix.Net, pgsql-general@hub.org
Subject: Re: [SQL] oracle rownum equivalent?
In-Reply-To: <3.0.1.32.20000608082010.0092bdb0@pop.spectrumtelecorp.com>
References: <3.0.1.32.20000607101423.00930360@pop.spectrumtelecorp.com> <3.0.1.32.20000608082010.0092bdb0@pop.spectrumtelecorp.com>
* Save the following mbox file, import it into your mail client,
and reply-to-all from there: mbox
This inbox is served by DDX for PostgreSQL; see mirroring instructions
for how to clone and mirror all data and code used for this inbox