Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
shekhar_analyti
Specialist
Specialist

How to handle data with self repeating columns with different name in rows ?

Hi All ,

How to handle data with self repeating columns with different name in rows ?

Self Repeating Columns with Different name.JPG

Thanks & Regards

Shekar

1 Solution

Accepted Solutions
sunny_talwar

It is a matter of fixing the format, underlying value isn't incorrect

Capture.PNG

View solution in original post

5 Replies
avinashelite

What is the output your excepting ?

for the first column

PurgeChar(field_name,'0123456789') as New_field_name

sunny_talwar

May be like this

Table:

LOAD A,

    B,

    PurgeChar(A, '0123456789') as NewA,

    KeepChar(A, '0123456789') as SNo

FROM

[..\..\Downloads\self repeating.xlsx]

(ooxml, no labels, table is Sheet1);

FinalTable:

LOAD DISTINCT SNo

Resident Table;

FOR i = 1 to FieldValueCount('NewA')

  LET vField = FieldValue('NewA', $(i));

  Left Join (FinalTable)

  LOAD SNo,

  B as [$(vField)]

  Resident Table

  Where NewA = '$(vField)';

NEXT

DROP Table Table;

shekhar_analyti
Specialist
Specialist
Author

Hi Sunny ,

I guess , age is not coming properly !

sunny_talwar

It is a matter of fixing the format, underlying value isn't incorrect

Capture.PNG

shekhar_analyti
Specialist
Specialist
Author

As always .. Take a bow !!