By using this site, you agree to our updated Privacy Policy and our Terms of Use. Manage your Cookies Settings.
438,372 Members | 1,950 Online
Bytes IT Community
+ Ask a Question
Need help? Post your question and get tips & solutions from a community of 438,372 IT Pros & Developers. It's quick & easy.

connectby

P: n/a
hi

I have menu table:
id | integer | not null default
nextval('public.menu_id_seq'::text)
parent_id | integer |
description | text |

I do select:
test=> SELECT * FROM connectby('menu','id','parent_id','2',0,'~') t(id
integer, parent_id integer, level int, branch text);
id | parent_id | level | branch
----+-----------+-------+-------------
2 | | 0 | 2
4 | 2 | 1 | 2~4
7 | 4 | 2 | 2~4~7
10 | 7 | 3 | 2~4~7~10
16 | 10 | 4 | 2~4~7~10~16
9 | 4 | 2 | 2~4~9

How am I able to select description file from menu table, not only id,
parent_id, level, branch fields?

--
WBR, sector119
---------------------------(end of broadcast)---------------------------
TIP 8: explain analyze is your friend

Nov 12 '05 #1
Share this question for a faster answer!
Share on Google+

This discussion thread is closed

Replies have been disabled for this discussion.