[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: [Chicken-users] Re: postgresql egg question

From: Larry White
Subject: Re: [Chicken-users] Re: postgresql egg question
Date: Mon, 10 Jan 2005 17:11:46 -0500

I have an application that uses Postgresql stored functions (pgplsql).
 The only table-like result they can return is a ref-cursor.  So I can
(pg:query-tuples "Select * from list-users(1)")

but I don't know what to do with the returned object.  It's a list of
(1) tuple, but inside the tuple is just a string i believe.   I need
something I can iterate over and extract values from.

If I query the table directly "select * from core_user"  I get a list
of tuples with values.  That's  more or less what i need.

On Mon, 10 Jan 2005 22:51:22 +0100, Johannes Groedem <address@hidden> wrote:
> * Larry White <address@hidden>:
> > Is there any way to handle ref cursors as the return type from a
> > query using chicken's postgresql egg?
> Not quite sure I get what you want to do.  Something like this?
> #;3> (pg:query-tuples "BEGIN; SELECT reffunc('foo')" con)
> (#f #("foo"))
> #;4> (pg:query-tuples "FETCH 1 IN foo")
> (#("some value"))
> --
> Johannes Groedem <OpenPGP: 5055654C>
> _______________________________________________
> Chicken-users mailing list
> address@hidden

reply via email to

[Prev in Thread] Current Thread [Next in Thread]