Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Expand Variables in 1 line...

Hi There,

I really should let this go but is it possible to write this in 1 line of code?

I want it to be coded in the loadscript.

To make what I want work I have done the following.

Created 2 variables in QlikView:

1. vAsAtRollingType = =AsAtRollingField

2. vAsAtDateSelected = =$(vAsAtRollingType)

The second one just expants the first one.

e.g.

1. vAsAtRollingType = MyFieldWith1PossibleValueWhichIsJan-2012

2. vAsAtDateSelected = Jan-2012

The above works as a two step process. Can I write it in one?

e.g.

=Only(=$(vAsAtRollingType ))

Obviously the above doesn't work but something similar? Or does it have to be a 2 step process?

Ideally it could all be coded in the load script...

Thanks

1 Solution

Accepted Solutions
Gysbert_Wassenaar

Not sure what you're trying to do. Have a look at the attached example. I didn't create the variable in the script, but that doesn't matter. It'll work the same if you do create the variable in the script.


talk is cheap, supply exceeds demand

View solution in original post

2 Replies
Gysbert_Wassenaar

Not sure what you're trying to do. Have a look at the attached example. I didn't create the variable in the script, but that doesn't matter. It'll work the same if you do create the variable in the script.


talk is cheap, supply exceeds demand
Not applicable
Author

Thanks Gysbert,

It was syntax error on my part. Your sample was perfect thanks for that!