I am trying to select subtree by parent id in table:

create table categories(
        id int,
        parent_id int
);

I am fetching it by recursive plpgsql function, which works well.

When i use that function as part of rule operation, i am getting ERROR: stack depth limit exceeded.

I have tried to rewrite without recursion which cause infinite loop in rule.

Is it possible to sent dynamic structures in planer?
Or how to fetch subtree without change of table structure inside rule?

Thanks
        

--
Sent via pgsql-hackers mailing list (pgsql-hackers@postgresql.org)
To make changes to your subscription:
http://www.postgresql.org/mailpref/pgsql-hackers

Reply via email to