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

Re: Progress of asynchronous queries

From: "Jeroen T(dot) Vermeulen" <jtv(at)xs4all(dot)nl>
To: "Adriaan van Os" <adriaan(at)microbizz(dot)nl>
Cc: pgsql-interfaces(at)postgresql(dot)org
Subject: Re: Progress of asynchronous queries
Date: 2006-09-19 03:03:04
Message-ID: 11882.203.121.164.162.1158634984.squirrel@webmail.xs4all.nl (view raw or flat)
Thread:
Lists: pgsql-interfaces
On Mon, September 18, 2006 14:51, Adriaan van Os wrote:

> Still, the issue I raised was about tracing the progress of a SQL command
> in general, not about the
> specific case of using a cursor instead.

True, and dealing with cursors is extra work in libpq.

In the C++ API OTOH there is a class that lets you treat a cursor more or
less as a regular query result.  It's set to be replaced with a more
modern version, but it's usable: chunks of result data are fetched on
demand, i.e. as you access them.  If you had something like that, all
you'd have to do is issue your query as before, process your data as
before, and update your progress display after every n rows of processing.
 You wouldn't really notice any of the complexity underneath.


Jeroen



In response to

pgsql-interfaces by date

Next:From: Jan van der WeijdeDate: 2006-09-20 12:38:23
Subject: PQsetdbLogin() and PQconnectdb() fail on HPUX11i 64 bits with empty servername
Previous:From: D'Arcy J.M. CainDate: 2006-09-18 23:05:06
Subject: Re: Python interfaces

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