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

Re: Selecting tree data



"D. Dante Lorenso" <dante(at)lorenso(dot)com> writes:

> Pat Maddox wrote:
>> I'd like to store some tree data in my database.  I want to be able to
>> sort the data but maintain a tree structure....
>> Is it possible to pull all the data like that with one query?  How do
>> I need to structure the table, and what query do I have to run in
>> order to make it happen?
>
> You need to look at the connectby function which is part of contrib.

Or ltree. Depending on how static your data is and what else you need to do
with it.


-- 
  Gregory Stark
  EnterpriseDB          http://www.enterprisedb.com



Home | Main Index | Thread Index

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