Re: Dynamic SELECT condition - Mailing list pgsql-sql

From Oleg Samoylov
Subject Re: Dynamic SELECT condition
Date
Msg-id b3vldk$1a47$1@news.hub.org
Whole thread Raw
In response to Dynamic SELECT condition  ("Victor Yegorov" <viy@pirmabanka.lv>)
List pgsql-sql
Victor Yegorov wrote:
> I mean, I know the id of a root object, it's 3. If I'll extract with
> condition parent_id =3D 3, then I'll get only 2 rows. I'd like to have a
> recursive result set - while there are records in the table for which
> count(next_level_parent_id =3D=3D this_level_child_id) > 0, select parent_i=
> d, child_id.
> 
> I hope you'll understand my problem.

As I can undestand you problem, I can use function returned resultset 
for this purpose.

-- 
Olleg Samoylov



pgsql-sql by date:

Previous
From: Oleg Samoylov
Date:
Subject: Re: Executing SQL commands via triggers without the use of procedures
Next
From: Victor Yegorov
Date:
Subject: Re: Dynamic SELECT condition