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

Announcements
Join us in Bucharest on Sept 18th for Qlik's AI Reality Tour! Register Now
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

Loading columns/fields with dynaminc names into new table

Hello QV Experts!

I am trying to load into table field from other table, where name of columns are definefd by variable.

So we have in one table columns with year&month:

Capture.JPG

then I made loop to catch all columns from "Source_Table" and put them into "Base" table

for i = 1 to 16 //we have 16 columns to check

    let Name = FieldName($(i),’Source_Table');

         Left join(Base)

     load
         
Plant,
         
Material,
         
$(Name) as $(NowYear)$(i)
         
Resident Source_Table;

next i


But as result I got:

Capture.JPG


Any ideas how to import all values instead of only field names?

Thanks!

1 Reply
Gysbert_Wassenaar
Partner - Champion III
Partner - Champion III

Are you perhaps looking for the CrossTable load?


talk is cheap, supply exceeds demand