Re: Fast reference without an index? - Mailing list pgsql-hackers

From pgsql@mohawksoft.com
Subject Re: Fast reference without an index?
Date
Msg-id 16737.24.91.171.78.1107898174.squirrel@mail.mohawksoft.com
Whole thread Raw
In response to Re: Fast reference without an index?  (Tom Lane <tgl@sss.pgh.pa.us>)
Responses Re: Fast reference without an index?  (Alvaro Herrera <alvherre@dcc.uchile.cl>)
List pgsql-hackers
> pgsql@mohawksoft.com writes:
>> Is there a way, and if I'm being stupid please tell me, to use something
>> like a row ID to reference a row in a PostgreSQL database? Allowing the
>> database to find a specific row without using an index?
>
> ctid ... which changes on every update ...

Well, how does an index do it? Say this:

select * from mytable where name = 'foo';

The index must return something. Say I have a row that it constantly being
updated, or has an original item inserted. An item which is valid within
my transaction, and an item which has just be inserted but has a
transaction id greater than mine.


Dosn't the index have some base number which points to the first valid
occurance of the row, and then the valid row is found based on the
transaction ID, or has PG changed? Is that the ctid?




pgsql-hackers by date:

Previous
From: Tom Lane
Date:
Subject: Re: "external indices" ...
Next
From: "Marc G. Fournier"
Date:
Subject: Re: "external indices" ...