Do not input private or sensitive data. View Qlik Privacy & Cookie Policy.
Skip to main content

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
alex59800
Contributor II
Contributor II

Customer Hierarchy issue script

Hi all,

Here is a challenge for scripts experts concerning Hierarchy issue. To be as clear as possible, i attach an excel with my question. Thanks a lot guys for your answer.

Alex

2 Replies
alex59800
Contributor II
Contributor II
Author

please ? anyone could help me ?

Thanks a lot

Not applicable

Use the above script and

HIER:

LOAD [HIERARCHY (Father)] as ParentID,

     [HIERARCHY (Son)] as NodeID,

     [HIERARCHY (Father)] as NodeName

FROM

Hier.xlsx

(ooxml, embedded labels, table is Sheet1);

HIERFINAL:

Hierarchy(NodeID, ParentID, NodeName)

Load

*

Resident HIER;

Concatenate('HIERFINAL')

LOAD

DISTINCT

NodeName1,

NodeName1 as NodeID

Resident HIERFINAL;

drop table HIER;

Create a table box with NodeName1, NodeName2, NodeName3, NodeID to see the output