[Twisted-web] my first post, writing a Web interface to a PostgreSQL db

Michele Simionato michele.simionato at gmail.com
Fri Oct 14 07:23:46 MDT 2005


On 10/14/05, Valentino Volonghi aka Dialtone <dialtone at divmod.com> wrote:
> On Fri, Oct 14, 2005 at 10:34:36AM +0000, Michele Simionato wrote:
>
> Hi Michele :)

Hi Valentino! (funny to write to you in a foreign language ;)

> There are 2 projects that I know of that work with twisted and databases (or
> postgresql) that are worth a try.

I will have a look at them

> Lazy query functionality requires you to store the cursor that run the query
> somewhere (togheter with the connection from which it was created) so that you
> can use fetchmany() on it. There is no other way that comes to my mind.

Trouble is, .fetchmany() does not work. It first perform the full query (having
the user to wait 10 minutes in my example) and then it returns the results
in bunches. Also LIMIT and OFFSET do not work. I want to resume an already
started query, not to restart the full query and extracts a subset of it.

I don't see any way to do that in the DB API 2.0, and I am beginning to suspect
that it is much harder than I expected ...

           Michele Simionato



More information about the Twisted-web mailing list