Skip site navigation (1) Skip section navigation (2)

Re: Incremental results from libpq

From: "Goulet, Dick" <DGoulet(at)vicr(dot)com>
To: "Frank van Vugt" <ftm(dot)van(dot)vugt(at)foxi(dot)nl>,"Greg Stark" <gsstark(at)mit(dot)edu>
Cc: <pgsql-interfaces(at)postgresql(dot)org>
Subject: Re: Incremental results from libpq
Date: 2005-11-11 20:17:10
Message-ID: (view raw, whole thread or download thread mbox)
Lists: pgsql-interfaces

	With a lot of things Oracle the real answer is: it depends.

	For a simple "select * from <table_name>" even with a where
clause you may simply get the results one row at a time as they are
extracted & deemed appropriate for the result set.  But if you've
included a group by or order by clause, or a union/intersect/minus
clause then yes, the database will assemble results before sending them
to the client.

	Also Oracle supports cursors which allow you to pop one or more
rows off of the result set at a time.  The way Postgresql returns data
all at once is different. 

Dick Goulet
Senior Oracle DBA
Oracle Certified DBA

-----Original Message-----
From: pgsql-interfaces-owner(at)postgresql(dot)org
[mailto:pgsql-interfaces-owner(at)postgresql(dot)org] On Behalf Of Frank van
Sent: Thursday, November 10, 2005 3:33 PM
To: Greg Stark
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: [INTERFACES] Incremental results from libpq

> > If I'm informed correctly then Oracle and others are generating
> > the complete static result set on the server-side, which will then
> > stay cached until all rows/chunks are fetched.

> That's obviously not true. Try doing "select * from huge_table" on
> and you'll see records start appearing immediately.

Then it seems I haven't (been informed correctly) :)

Now, given that OCI is offering some kind of asynchronous interface as
how are they handling an error occuring after a partial result-set has
retrieved by the client?



---------------------------(end of broadcast)---------------------------
TIP 1: if posting/reading through Usenet, please send an appropriate
       subscribe-nomail command to majordomo(at)postgresql(dot)org so that your
       message can get through to the mailing list cleanly


pgsql-interfaces by date

Next:From: Alvaro HerreraDate: 2005-11-13 15:24:01
Subject: Re: Incremental results from libpq
Previous:From: Frank van VugtDate: 2005-11-10 20:33:20
Subject: Re: Incremental results from libpq

Privacy Policy | About PostgreSQL
Copyright © 1996-2017 The PostgreSQL Global Development Group