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

Announcements
Want to see what's currently in public preview? We've pulled it all together in one place. Check it out here
cancel
Showing results for 
Search instead for 
Did you mean: 
dennysetiawan
Partner - Contributor III
Partner - Contributor III

Advance Transpose Case

Hi Community,

I have a table like this:

Qst_MTM_source.jpg

I want to transpose that table, so my expectation output should be like this:

Qst_MTM_expect.jpg

Could you show me the best practice or script solution to have an output like above?

Herewith I attach my source data.

Thank you.

Labels (1)
1 Reply
sunny_talwar
MVP
MVP

Try this

Table:

CrossTable(DATE, VALUE, 5)

LOAD PRODUCT,

    RANGE,

    FOB,

    Port,

    MTM,

    [42737.000000],

    [42738.000000],

    [42739.000000],

    [42740.000000],

    [42741.000000],

    [42744.000000],

    [42745.000000]

FROM

[..\..\Downloads\Qst_MTM.xlsx]

(ooxml, embedded labels, table is Source, filters(

Transpose()

));


FinalTable:

NoConcatenate

LOAD PRODUCT,

Date(RANGE) as RANGE,

FOB,

Port,

MTM,

Date(Num#(DATE)) as DATE,

Num(VALUE) as VALUE

Resident Table;


DROP Table Table;


Capture.PNG