Skip site navigation (1) Skip section navigation (2)

Peripheral Links

Header And Logo

PostgreSQL
| The world's most advanced open source database.

Site Navigation

Search for
  Advanced Search

tree-structured query



in a simple tree structured table

table t(
  id primary key,
  pnt_id references t( id ),
  name
);

does anyone know an easy howbeit sneaky way of determining ancestory and decendency without recursive functions,

select name from t where exists <ancestor or descendent>

thanks for insight


Get your own web address for just $1.99/1st yr. We'll help. Yahoo! Small Business.

Home | Main Index | Thread Index

Privacy Policy | PostgreSQL Archives hosted by Command Prompt, Inc. | Designed by tinysofa
Copyright © 1996 – 2008 PostgreSQL Global Development Group