pg 7.3, cursors, and prepared queries

From: Eric Ridge <ebr(at)tcdi(dot)com>
To: Pgsql-General <pgsql-general(at)postgresql(dot)org>
Subject: pg 7.3, cursors, and prepared queries
Date: 2004-03-26 20:08:29
Message-ID: 596DBA87-7F61-11D8-A97A-000A95BB5944@tcdi.com
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-general

Is it really true that prepared statements cannot be used with cursors?

PREPARE foo(int8, text) AS <some really complicated query with a
bazillion joins that takes forever to plan>;
DECLARE foo_cursor CURSOR FOR EXECUTE foo(12::int8, 'some text');
ERROR: syntax error at or near "EXECUTE" at character 31

I've tried with 7.3, and w/ 7.4 (though I can't upgrade to 7.4 yet).

Please, say it ain't so. Tell me I'm doing something wrong!

eric

Browse pgsql-general by date

  From Date Subject
Next Message Pablo Montilla 2004-03-26 20:25:44 Waiting for Commit
Previous Message Tom Lane 2004-03-26 19:37:13 Re: simple join query runs very slowly