Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi All,
I am trying to build a country hierarchy. Please help.
This is my data table where i have the country field.
SQL Select DEALER, COUNTRY,WAVE,...,....
From TABLE1 WHERE ENABLED='YES';
i created a below table and tried for country hierarchy
NODE_ID | NAME | PARENT_ID |
1 | ALL MARKET | NULL |
2 | GCC MARKET | 1 |
3 | Abu Dhabi | 2 |
4 | Bahrain | 2 |
5 | Dubai-SZR | 2 |
6 | Garhoud | 2 |
7 | Iraq | 2 |
8 | Jeddah | 2 |
9 | Jordan | 2 |
10 | Khobar | 2 |
11 | Kuwait - LR | 2 |
12 | Kuwait | 2 |
13 | Lebanon-JR | 2 |
14 | Lebanon-LR | 2 |
15 | Marrakech | 1 |
16 | Morocco | 1 |
17 | Oman | 2 |
18 | Qatar | 2 |
19 | Rabat | 1 |
20 | Casablanca | 1 |
21 | Riyadh | 2 |
22 | Sharjah | 2 |
23 | Tunisia | 1 |
24 | Algeria | 1 |
25 | Azerbaijan | 1 |
26 | Egypt | 1 |
Thanks.
My mistake. Try:
Hierarchy (NODE_ID, PARENT_ID, COUNTRY, Parent, COUNTRY, PathName)
Then use PathName. Else re-upload your sample qvw.
Update: Corrected the field reference
Hi Tresesco,
Thanks you for your time and support.
PathName is displaying empty.
I am uploading my QV file.
Appreciate you could help me to fix this issue.
Thanks.
Note my update above.
Thanks a lot Tresesco,
I have one last question. If i select directly "All Market" or "GCC" is not giving any result.
I have click the - symbol to get the result. It is there is any other way ? so that if i select "All Market" it will display the result.
Thanks
Yes, there is. You have to use HierarchyBelongsTo. Please refer the link I provided above for details.
Thank you for your support