Hi all,

I'm using 6.0.1  and having problems trying to use  in-query.

First: in-query is the only function that can use cursors, but, unlike the other row returning functions (query, query-rows, query-maybe-row), in-query doesn't appear to understand Postgresql array fields - they are returned as "unreadable". That's a significant problem for me: I have a query that may return a large number - perhaps thousands - of rows which contain array fields. I need to process those fields and insert derived information back into the database before passing on the results of the query to the caller.

I can work around it by getting a list of identifiers for matching rows from a separate query and then iterating the list fetching the rows separately using one of the query functions that works ... but even fetching in groups that will be a lot slower than keep a cursor open on a single query.


Second ... and this is just annoying ... it seems that, unlike the other row returning functions, in-query requires that the result columns be enumerated - i.e. you can't say "select * from ..." to retrieve arbitrary tuples. That's inconvenient when you really want the whole record and even more so if the columns aren't known statically, which forces the SQL to be assembled dynamically [never ideal, but necessary sometimes]. I don't have a dynamic situation here, but I have encountered them in the past. This seems like a needless limitation.

Have either of these things changed in 6.1?

Thanks,
George
____________________
 Racket Users list:
 http://lists.racket-lang.org/users

Reply via email to