Qlik Community

QlikView Creating Analytics

Discussion Board for collaboration related to Creating Analytics for QlikView.

rendiyan
New Contributor III

[ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

Dear QlikView,

I have generate data with hierarchy function and result like below :

Untitled.png

As we now, with hierarchy function qlikview will generate all level that possible.

But will leave blank to the field that certain row that not use that field.

In other side, my client expectation the result will be like below :

Untitled.png

And my question is,

is that result achieveable with QLikView load script?

if it is yes, please help me with some guide.

Many Thanks

5 Replies

Re: [ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

Can you try something like this?

If([Node Name2]=FindOneOf([Node Name2], '0123456789'), Previous([Node Name1]) as [Node Name2]

rendiyan
New Contributor III

Re: [ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

what does it mean?

i've tried it and nothing happen.

Re: [ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

My intention is this?

Sample:

LOAD RowNo() as ID,

     [Node Name1],

     [Node Name2],

     [Node Name3],

     [Node Name4]

FROM

Table;

Final:

NoConcatenate

LOAD ID, [Node Name1], If(FindOneOf([Node Name2], '0123456789'), [Node Name1],[Node Name2]) as [Node Name2]

Resident Sample;

DROP Table Sample;

Same Way, You can use for next 2 nodes ..

Re: [ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

Will this issue resolved? I know this is long time. But, you have to understand how Qlik community works for helpers. If it is, Please close this thread ..

Re: [ASK]Hierarchy-How to fill empty fields with the latest n-level fields?

try like this

if (len( trim( [Node Name2]))=0, Peek([Node Name1]),[Node Name2]) as [Node Name2]


similiar you could apply for other columns too

Community Browser