This is a migrated thread and some comments may be shown as answers.

[Solved] Self referencing hierarchy using calcuated column?

1 Answer 94 Views
Grid
This is a migrated thread and some comments may be shown as answers.
Laura
Top achievements
Rank 1
Laura asked on 01 May 2009, 01:56 PM
I am trying to figure out if what I want to do is possible. I have a table called geographic coverages. It is a table of all geographic names in the world. There are 4 different types of name: LR (region) LC (country) LS (state) LU (urban).
So a geo_name could be LR:na (which would be north america)
or LC:na.us  (which would be united states in north america)
or LS:na.us.ny  (which would be new york in united states in north america)
or LC: na.us.ny.al   (which would be albany in ny in us in na).


These names are all in a flat table with only 2 columns - geo_name and description.
I want to create a grid so the user can choose one or more geo_names.
Is there any way to use this one column to create a hierarchical grid of region drilling down to country down to state down to urban?

Thanks

1 Answer, 1 is accepted

Sort by
0
Sebastian
Telerik team
answered on 05 May 2009, 01:47 PM

Hello Laura,

You can utilize the self-referencing hierarchy feature of RadGrid in this case provided that you set the appropriate ID->ParentID relations between the individual rows in the source table. Review the following resources which explain this feature of the grid and how to configure it:

http://demos.telerik.com/aspnet-ajax/grid/examples/hierarchy/selfreferencing/defaultcs.aspx
http://www.telerik.com/help/aspnet-ajax/grdselfreferencinghierarchy.html

Best regards,

Sebastian
the Telerik team

Instantly find answers to your questions on the new Telerik Support Portal.
Check out the tips for optimizing your support resource searches.
Tags
Grid
Asked by
Laura
Top achievements
Rank 1
Answers by
Sebastian
Telerik team
Share this question
or