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

Announcements
Qlik Open Lakehouse is Now Generally Available! Discover the key highlights and partner resources here.
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Need Help - Create dynamic columns & rows

Hello All,

I have requirement to convert the data from Table 1 to Table 2 in QV 11 SR1  as shown in screenshot, number of Rows in Table 1  is dynamic, means column creation of Table 2 in qlikview witll be dynamic as well.

Transpose_Dynamic.png

I am really new in Qlikview and will appreciate any guidance.

Thanks,

Pooja

4 Replies
Not applicable
Author

Any inputs please ?

Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

It's a very bad idea and I have no idea why you would ever want to do that, but this should do what you want:

T2:

load RowNo() as id, * inline [

Name, Value

Chipset,Chip 1

Chipset,Chip 2

Chipset,Chip 3

Modem,Mod 1

Modem,Mod 2

Wireless,Wir 1

Wireless,Wir 2

];

 

T3:

load RowNo() as id, Value as Chipset

Resident T2 where Name = 'Chipset';

join(T3)

load RowNo() as id, Value as Modem

Resident T2 where Name = 'Modem';

join(T3)

load RowNo() as id, Value as Wireless

Resident T2 where Name = 'Wireless';

drop field id;

drop table T2;

You can replace the inline load with a load statements that load your Table 1 data.


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks Gysbert for your response. It will work , if the Name field value are constant.

Solution of this problem become much simpler with  the updatde requirements.

Was able to achieve it by using Pivot Table , Name as Dimension & value as expression.

jeffmartins
Partner - Creator II
Partner - Creator II

Hi poojasaxena,

I've had a problem similar with yours about creating fields dynamically and I solved it using the code of the attached file.

Hope this helps you.

Regards