|
|
|||||||||
|
|||||||||
|
|||||||||
| |
|||
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Display Modes |
|
#1
|
|||
|
|||
|
I need to take the example data below and put it in a treeview control, but since there's no parent/child relationship and it's all in one column. I don't know how to approach this.
Our table as it sits right now, has the column (which is a primary key / nvarchar(100)) in question looking like: D1 D1.01 D1.01.01 D1.01.01.02 D1.01.01.02.003 D1.01.02 D1.01.02.02 D1.01.02.03 E1 E1.01 E1.01.01 E1.01.01.02.003 E1.01.02 E1.01.02.02 E1.01.02.033 E1.01.02.04 So, I'm thinking I have to look for the first "dot" and pull out the characters before that for the first nodes: D1 E1 ....then look for the 2nd "dot" and pull every thing before that for the second drill down node if the user were to click on either "D1" or the "E1" nodes..and they'd see: D1 D1.01 E1 E1.01 I think there's a strip or some function to do that, but I'm a bit stumped right now. I've seen some stuff on hierarchical data, but I'm not gettin' it. Any suggestions are welcome! Thanks! |
![]() |
| Viewing: Dev Articles Community Forums > Databases > Microsoft SQL Server > Parse number data w/ dots for treeview |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|