Complex table/query

From: Andy Lewis <alewis(at)mpsi(dot)net>
To: mailto: ;
Subject: Complex table/query
Date: 1998-06-01 14:59:59
Message-ID: Pine.LNX.3.95.980601093055.16097A-100000@shell.mpsi.net
Views: Raw Message | Whole Thread | Download mbox | Resend email
Thread:
Lists: pgsql-sql

I have the following info to store in a DB:

[1] Keep a record of category items as well as owner name, street, state,
zip..etc ....

[2] Keep a running tab on the number of items overall in the DB

[3] Keep a running tab on the number of items overall in the DB by state.

I am allowing the viewer to first select the state and then the city and finally
the category. Once they arrive at the category page I want to show them the
number of items that are in the DB for that state, city and category.

I am using PHP/Postgres to make a <select></select> statement that will show the
categories, of which there are around 115. The obvious 50 states....

I can build this ridulious SQL statement that just eats the hell out of the
processor.

Does anyone have any ideas how I can query/build this thing?

Thanks

Andy

Browse pgsql-sql by date

  From Date Subject
Next Message Christian Guenther 1998-06-01 18:02:56 soundex more or less exact
Previous Message Piotr Adamiak 1998-06-01 12:29:37 Where is the problem ?