Ask a Question related to ASP Database, Design and Development.
-
Sam Churchill #1
Hierarchical listings
I have need to show a list of areas indented hierarchically on an ASP web
page like the following example.
The World
Europe
United Kingdom
England
Wales
Scotland
Northern Ireland
France
Germany
The Americas
North America
State 1
State 2
South America
Columbia
...
The data is held in a database table which has 3 fields (areaID, area,
subAreaOf). The data from the above example would be as follows.
areaID area subAreaOf
1 The World
2 Europe 1
3 United Kingdom 2
4 England 3
5 Scotland 3
6 Wales 3
......You get the idea...
Any idea how to generate the indented listings as economically as possible
on the queries.
Thanks,
Sam
Sam Churchill Guest
-
TV Listings Module
Does anyone have any experience in developing a TV lisings module similar to what is on Yahoo! TV or on the TV Guide home page. Something that is... -
How to supress directory listings?
When you enter a URL into the browser (not a .cfm file, for example), it lists the various files and directories. Using Apache, there's a file... -
web designer directory - free listings
hi. www.labelsound.com now has free listings for web designers, graphic designers and photographers. We're a music licensing site who provide music... -
Directory listings
Hey guys, I'm really new to the wole php thing, have never even touched it before and have been looking through php.net, and what i am basically... -
Error code listings
Is there a published list of IFS error codes available somewhere online? I get the occastional one and have no way of finding out what it means. ... -
Sam Churchill #2
Hierarchical listings
I have need to show a list of areas indented hierarchically on an ASP web
page like the following example.
The World
Europe
United Kingdom
England
Wales
Scotland
Northern Ireland
France
Germany
The Americas
North America
State 1
State 2
South America
Columbia
...
The data is held in a database table which has 3 fields (areaID, area,
subAreaOf). The data from the above example would be as follows.
areaID area subAreaOf
1 The World
2 Europe 1
3 United Kingdom 2
4 England 3
5 Scotland 3
6 Wales 3
......You get the idea...
Any idea how to generate the indented listings as economically as possible
on the queries.
Thanks,
Sam
Sam Churchill Guest
-
martin de vroom #3
Re: Hierarchical listings
hi sam,
here are some good lnks to solve your puzzle
[url]http://www.intelligententerprise.com/001020/celko1_1.shtml[/url] --- Nested sets
[url]http://www.dbazine.com/tropashko4.html[/url]
[url]http://vyaskn.tripod.com/hierarchies_in_sql_server_databases.htm[/url] ------
-------------excellent
[url]http://support.microsoft.com/default.aspx?scid=kb%3Ben-us%3B248915[/url]
[url]http://tinyurl.com/c17l[/url]
[url]http://www.yafla.com/papers/sqlhierarchies/sqlhierarchies.htm[/url]
If you are using SQL server and deciede to get these values with recursion
you will hit the 32 limit (i belive there are more countries that this in
the world:) )
The solution would probabally be to use a language that doesn't have this
barrier,
alternatvly joe celko's nested sets (first link above) is excellent if you
can get you head around it, and achive inserts, updates, deletes..
cheers
martin.
"Sam Churchill" <ngs@samchurchill.co.uk> wrote in message
news:Nf0Ra.48096$9C6.2542073@wards.force9.net...> I have need to show a list of areas indented hierarchically on an ASP web
> page like the following example.
>
> The World
> Europe
> United Kingdom
> England
> Wales
> Scotland
> Northern Ireland
> France
> Germany
> The Americas
> North America
> State 1
> State 2
> South America
> Columbia
> ...
>
>
>
> The data is held in a database table which has 3 fields (areaID, area,
> subAreaOf). The data from the above example would be as follows.
>
> areaID area subAreaOf
> 1 The World
> 2 Europe 1
> 3 United Kingdom 2
> 4 England 3
> 5 Scotland 3
> 6 Wales 3
> .....You get the idea...
>
> Any idea how to generate the indented listings as economically as possible
> on the queries.
>
> Thanks,
>
> Sam
>
>
>
martin de vroom Guest
-
Manohar Kamath [MVP] #4
Re: Hierarchical listings
Sam,
While I don't have the exact code, you might want to look at some recursive
code. Perhaps a code on threaded discussions should help you.
--
Manohar Kamath
Editor, .netBooks
[url]www.dotnetbooks.com[/url]
"Sam Churchill" <ngs@samchurchill.co.uk> wrote in message
news:D40Ra.48094$9C6.2541778@wards.force9.net...> I have need to show a list of areas indented hierarchically on an ASP web
> page like the following example.
>
> The World
> Europe
> United Kingdom
> England
> Wales
> Scotland
> Northern Ireland
> France
> Germany
> The Americas
> North America
> State 1
> State 2
> South America
> Columbia
> ...
>
>
>
> The data is held in a database table which has 3 fields (areaID, area,
> subAreaOf). The data from the above example would be as follows.
>
> areaID area subAreaOf
> 1 The World
> 2 Europe 1
> 3 United Kingdom 2
> 4 England 3
> 5 Scotland 3
> 6 Wales 3
> .....You get the idea...
>
> Any idea how to generate the indented listings as economically as possible
> on the queries.
>
> Thanks,
>
> Sam
>
>
Manohar Kamath [MVP] Guest
-
Marc #5
Re: Hierarchical listings
my tree code does exactly what your asking for:
[url]http://www.braincast.nl/?deeplink=dhtml/asptree[/url]
click view and look at the 'simple' version, you can download
a zip file with all the samples...
[url]http://www.braincast.nl/dhtml/asptree/files/tree.asp[/url]
"Sam Churchill" <ngs@samchurchill.co.uk> wrote in message
news:D40Ra.48094$9C6.2541778@wards.force9.net...> I have need to show a list of areas indented hierarchically on an ASP web
> page like the following example.
>
> The World
> Europe
> United Kingdom
> England
> Wales
> Scotland
> Northern Ireland
> France
> Germany
> The Americas
> North America
> State 1
> State 2
> South America
> Columbia
> ...
>
>
>
> The data is held in a database table which has 3 fields (areaID, area,
> subAreaOf). The data from the above example would be as follows.
>
> areaID area subAreaOf
> 1 The World
> 2 Europe 1
> 3 United Kingdom 2
> 4 England 3
> 5 Scotland 3
> 6 Wales 3
> .....You get the idea...
>
> Any idea how to generate the indented listings as economically as possible
> on the queries.
>
> Thanks,
>
> Sam
>
>
Marc Guest



Reply With Quote

