Qlik Community

QlikView App Development

Discussion Board for collaboration related to QlikView App Development.

Announcements
If you are a Qlik Insight Bot user, join this collaborative group: JOIN GROUP
Partner
Partner

Recursive table

Hi,

I've got a question concerning a straight table:

I have a table like:

Name          ParentName    NameStatus.

John            Charles            Alive

Charles          Andrew            Dead

And I'd like to have a straight table like this:

Name        NameStatut      ParentName      ParentStatus.

John              Alive                Charles            Dead

I've tried set analysis like P(ParentName), lookup/peek doesn't exist in charts and only(TOTAL Status) but No Way!

Due to the amount of data, I need to keep one this information into one table in my datamodel.

Thank you!

1 Solution

Accepted Solutions
Highlighted
Honored Contributor III

Re: Recursive table

=TextBetween(Concat(TOTAL Name &'|' & NameStatus,','),ParentName & '|',',')

View solution in original post

6 Replies
Highlighted
Honored Contributor III

Re: Recursive table

Temp:

Load * Inline [

Name,ParentName,NameStatus

John,  Charles,Alive

Charles,Andrew,Dead ];

Left Join(Temp)

Load Name as ParentName,NameStatus As ParentStatus Resident Temp;

Highlighted
Partner
Partner

Re: Recursive table

Thanks

That's way my first attempt. It's working but It's like to avoid a resident load as this table is huge.

Is there a way to do it within the chart?

Thx

Highlighted
Honored Contributor III

Re: Recursive table

=TextBetween(Concat(TOTAL Name &'|' & NameStatus,','),ParentName & '|',',')

View solution in original post

Highlighted
Partner
Partner

Re: Recursive table

I don't know if this is the best practice but it works perfectly in my case.

Thank you very much

Highlighted
Not applicable

Re: Recursive table

I found this a very easy way to deal with this problem (still using resident):

Load Name as ParentName, NameStatus as ParentStatus resident Table;

This will load again your table, but now associating ParentStatus with ParentName. The association with the other table is automatically stablished.

Highlighted
Partner
Partner

Re: Recursive table

Yes I see.

I asked it to remain as a single table because this is actually a linktable.

Cheers