Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Need to know how to create a variable from accross multiple files

I am reading in multiple files with the same file layout, except for a created variable in each load statement.

I want to be able to add (sum) each of the created variables, which provides me with a combination variable (combo).

For example, the variables are var1, var2, var3, etc.  Var1=1, Var2=10 and Var3=100.  I want a variable that is a combination of 111.  Combo = 111 or Combo = 101.... you get the idea.

Help.  So the question is:

Do I calculate a new variable?

Do I develop and expression?

Do I use the “aggr” function?

I am new at this so I might need detailed instructions. I have attached a brief PowerPoint description of the desired outcome.

Thanks in advance.

Mark

3 Replies
swuehl
MVP
MVP

I can't find the attachement.

Could you also post the current script you are using to load the files and variables?

I assume you should be able to use something like

Let vCombo = RangeSum(var1, var2, var3);

Anonymous
Not applicable
Author

Hi Mark,

I have seen that your tables are the same fields, why don't create the same field name with other values and combine it with group by?

Kind regards

Not applicable
Author

Hello,

if I got it right, it is about summing and grouping. Please find an approach attached.