Skip to main content

QlikView App Dev

Discussion Board for collaboration related to QlikView App Development.

Announcements
CUSTOMERS ONLY: Now accepting customer applications for the 2023 Luminary Program: SUBMIT NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
twanqlik
Creator
Creator

Transpose rows to columns

I'm trying to transpose the following table:

Input:

  

%Classification_KeyAttributeIDValue%Table
de_DE_7PH-CATALOG-EOP2037-10-10
de_DE_7PH-CATALOG-PRD-AUDIENCEB2B
de_DE_7PH-CATALOG-PRD-CTNREGTE
de_DE_7PH-CATALOG-PRD-TARGETPRD-308941
de_DE_7PH-CATALOG-SOP2016-10-04
de_DE_7PH-IsActivetrue
de_DE_7PH-IsDeletedfalse
de_DE_7PH-IsEnabledtrue

Output:

       

PH-CATALOG-EOPPH-CATALOG-PRD-AUDIENCEPH-CATALOG-PRD-CTNPH-CATALOG-PRD-TARGETPH-CATALOG-SOPPH-IsActivePH-IsDeletedPH-IsEnabled%Classification_Key
2037-10-10B2BREGTEPRD-3089412016-10-04truefalsetruede_DE_7

I'm really struggling with this. How to do this in the scripting part, not on the front-end

1 Solution

Accepted Solutions
6 Replies
sunny_talwar

sewialwork
Partner - Contributor III
Partner - Contributor III

You can check your options hereGroup by explanation‌ or here Multiple rows with different dimensions

AGB

vamsee
Specialist
Specialist

Hello,

I think you are looking for Generic Load

The GENERIC Load – QLIKIES

Generic LOAD

%Classification_Key,

AttributeID,

Value%Table

From Source;

twanqlik
Creator
Creator
Author

It creates 1 table per field.

It can work on the front-end, but this is not what i'm searching for

twanqlik
Creator
Creator
Author

Thanks, this worked:

Table:

LOAD * INLINE [

    ID, NAME, VALUE

    1, name1, val1

    1, name2, val2

    2, name1, val3

    2, name2, val4

    3, name1, val5

    3, name2, val6

    4, name1, val7

    4, name2, val8

    5, name3, val9

];

FinalTable:

LOAD Distinct ID

Resident Table;

FOR i = 1 to FieldValueCount('NAME')

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

Left Join (FinalTable)

LOAD ID,

VALUE as [$(vField)]

Resident Table

Where NAME = '$(vField)';

NEXT i

DROP Table Table;