Re: [HACKERS] Show stopper ? (was: Re: "cruising" or "browsing" through tables using an index / ordering)

From: Bruce Momjian <maillist(at)candle(dot)pha(dot)pa(dot)us>
To: honza(at)ied(dot)com (Jan Vicherek)
Cc: scrappy(at)hub(dot)org, dustin(at)spy(dot)net, pgsql-questions(at)postgreSQL(dot)org, pgsql-hackers(at)postgreSQL(dot)org
Subject: Re: [HACKERS] Show stopper ? (was: Re: "cruising" or "browsing" through tables using an index / ordering)
Date: 1998-01-24 03:50:30
Message-ID: 199801240350.WAA01284@candle.pha.pa.us
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-hackers

>
> On Fri, 23 Jan 1998, The Hermit Hacker wrote:
>
> > I'm curious, but can the "Big (commercial) Boys" do this? If so,
> > can you please provide an example of which and how?
>
> Hmm, well, the one we are switching from does this ;-) (Informix 3.3
> ALL-II C interface). It's not SQL, tho.

Ah, the Informix ISAM interface that used to sit underneath the Informix
SQL engine.

> Important : I'm not looking for a "pure SQL" solution. I'm writing a C
> emulation library, so if it can be achieved via a call to a C Postgres
> function, it would be great.
>

You can put an index on the table, and embed a function inside the
engine to spin through the index, getting valid rows. The code is
already there to spin through the index, so you could just hook on to
the index, get the 'tid' and use that to get data from the physical
table. No locking, but you may get in trouble if other people are
reading the index. Maybe a quick lock-unlock would do it for you. Not
easy, because the engine really doesn't provide a user-friendly C
interface for this, but it could be done.

--
Bruce Momjian
maillist(at)candle(dot)pha(dot)pa(dot)us

In response to

Responses

Browse pgsql-hackers by date

  From Date Subject
Next Message Bruce Momjian 1998-01-24 03:53:27 Re: [QUESTIONS] Re: [HACKERS] Show stopper ? (was: Re: "cruising" or "browsing" through tables using an index / ordering)
Previous Message Jan Vicherek 1998-01-24 03:41:50 Attn PG gurus / coders : New approach for ORDER BY ? (was: Re: Show stopper ?)