all groups > inetserver asp general > june 2003 >
You're in the

inetserver asp general

group:

Linking of several tables in a heirarchical form


Linking of several tables in a heirarchical form Jacob
6/30/2003 5:11:10 PM
inetserver asp general:
I have a table, SYS_Locations, which lists all of the locations available
for a system.
I.E.:
1 -- Matrix Hall
2 -- Upstairs
3 -- Basement
4 -- Cabinet
5 -- Storage Building

Then, I have another table, LOC_TREE_REL which ties the previous locations
to one another.
I.E.:
1 -- 2 (Says Upstairs belongs in Matrix Hall)
5 -- 3 (Says Basement belongs in Storage Building)
3 -- 4 (Says the Cabinet is in the Basement which as shown in a previous
row, is in the Storage Building.)
All of the entries in LOC_TREE_REL include a self-ownership entry. (i.e. For
Matrix Hall, their is a 1 -- 1 entry, Upstairs has a 2 -- 2 entry, etc.

I need to be able to tie these locations together in some sort of list which
demonstrates heirarchy.

I'm considering using a drop-down select menu to do it such as:

Matrix Hall
---- Upstairs
Storage Building
---- Basement
---------Cabinet

However, I need some help with the code to perform such location connections
on-the-fly. Any help will be greatly appreciated.

Jacob


Re: Linking of several tables in a heirarchical form Aaron Bertrand [MVP]
6/30/2003 7:14:49 PM
Could you tell us what database and version you're using (SQL Server 7.0,
Access 95, FoxPro 2.0, dBase IV, Oracle 8i, etc.)?

And please follow up only in microsoft.public.inetserver.asp.db



[quoted text, click to view]

AddThis Social Bookmark Button