Re: [GENERAL] Using SETOF functions in SQL

2006-08-15 Thread Jeff Davis
On Tue, 2006-08-15 at 12:38 +0100, Pavel Velikhov wrote: > SELECT t1.node, t2.node, path FROM t1,t2, connections(t1.id, t2.id) as > path > > I get the notorious: ERROR: subquery in FROM may not refer to other > relations of same query level > The FROM list must be a list of relations, but in t

[GENERAL] Using SETOF functions in SQL

2006-08-15 Thread Pavel Velikhov
Hi!  Is it possible to use a function that returns SETOF and doesn't take constant parameters?I have a function 'connections(id1 bigint, id2 bigint) returns setof text' that I use to list all paths from id1 to id2. However, I haven't figured out a way to call the function with non-constant function