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

Announcements
ALERT: QlikView server communication interruptions following Microsoft Windows Domain Controller security updates
cancel
Showing results for 
Search instead for 
Did you mean: 
IAMDV
Master II
Master II

*** Rows to Columns... Is it Generic Load? ***

Dear All,

I have some data in rows and I need to convert them into columns to display in Table Box (without performing any aggregations). Do I need to use Generic Load or Is there any simple approach to transpose the data? I'm attaching some fictitious data for your reference. It will be great if someone can help me with this request.

Please check the Input Table and we need to convert the script to accomodate Output Table...

Note : There is not Unique/Primay Key within the data.

Many thanks in advance.

Cheers,

DV

www.QlikShare.com

Labels (1)
2 Replies
swuehl
Champion III
Champion III

Hi DV,

not sure if this is the best solution, but I would try something like

INPUT:

LOAD Field1,

     Field2,

     Field3,

     Field4,

     Measure

FROM

[.\Rows to Columns.xlsx]

(ooxml, embedded labels, table is [Input Table]);

 

For i = 1 to FieldValueCount('Measure')

Let a = FieldValue('Measure',$(i));

left join (INPUT) LOAD

'$(a)' as Measure,

'$(a)' as $(a)

AutoGenerate 1;

Next

drop field Measure;

Have a nice weekend,

Stefan

Not applicable