query large amount of data in c++ using libpq

From: "Felix Ji" <list(at)zflier(dot)com>
To: pgsql-general(at)postgresql(dot)org
Subject: query large amount of data in c++ using libpq
Date: 2007-08-19 04:34:48
Message-ID: ebd12ced0708182134ved3f729icd757ea19cc01d68@mail.gmail.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Hi all,
i am using PQexecParams() to "SELECT" about 3 million record in C++, and it
takes several minutes to make it done with used memory dramatically
incresed(about 200MB).
it seems when i using PQexecParams(), i can't use the query result before
all the data is sent to client.
is there something like server side cursor in libpq?
or is there any other way to do this in c++?
some articles say that query for large amount of data is automaticall
handled well by pg, but i can't see how.

thanks~~~~

Responses

Browse pgsql-general by date

  From Date Subject
Next Message Vance Maverick 2007-08-19 05:54:11 Re: SUBSTRING performance for large BYTEA
Previous Message Guy Rouillier 2007-08-19 04:19:45 Re: Writing most code in Stored Procedures