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

Announcements
Qlik Connect 2026 Agenda Now Available: Explore Sessions
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

field values assign variable

Hi,

i have loaded a table into my script

LOAD VariableName,

     VariableValue,

     VariableType,

     VariableFormat

FROM

(ooxml, embedded labels, table is [Color Settings]);

i Need to create variable with these field names.

can somebody please help me

1 Solution

Accepted Solutions
Anonymous
Not applicable
Author

PFA,

Hope this helps..........

View solution in original post

21 Replies
Not applicable
Author

If your Table Name is Tab:

Tab:

LOAD

VariableName,

     VariableValue,

     VariableType,

     VariableFormat

FROM

(ooxml, embedded labels, table is [Color Settings]);

Let VariableName= peek('VariableName',0,'Tab');

Let VariableValue= peek('VariableValue',0,'Tab');

Let VariableType= peek('VariableType',0,'Tab');

Let VariableFormat= peek('VariableFormat',0,'Tab');

Add that in a for loop if you have more than 1 Color.

amit_saini
Master III
Master III

Hi,

Do you mean to create variables by using fields VariableName ,VariableValue and so on....?????

Thanks,
AS

Not applicable
Author

Hi Amit saini,

Yes i need to create variables by using fields VariableName ,VariableValue and so on...

amit_saini
Master III
Master III

Hi,

You can do like this (Press CTRL + ALT +V and set the value of variables, they way i did for vV1 ,vV2 and so on)  or follow Eva POLINI suggestion also, both will work:

Thanks,

AS

Not applicable
Author

It you run my script, you will have 4 variables : VariableName, VariableValue, VariableType, VariableFormat.

amit_saini
Master III
Master III

Eva,

I know this will also work, I suggested him one more way of assigning values to different variables.

Thanks,
AS

Not applicable
Author

Sorry, my bad !! I read to fast... for any reason, I read "do both in the same time...."

Not applicable
Author

Hi I created the variable but i am not getting the data.

amit_saini
Master III
Master III

No Problem !

Cheers,

AS