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: 
AmCh
Creator
Creator

ValueLoop

Hello all,

I would like to use the ValueLoop with non-decimal increment.

Since this is not possible with ValueLoop, is there another alternative?

 

Many thanks in advance.

Yours sincerely,

Amor

1 Solution

Accepted Solutions
Or
MVP
MVP

Set vValue = 10;

for i=1 to 99

Set vValue = vValue + pi()/e();  /* Your increment goes in this line*/

Load $(vValue) as SyntheticDimension

Autogenerate(1);

next

 

You could probably do this more efficiently with just autogenerate and the row number, but since I'm not sure exactly what sort of increment you're trying to work with, it's hard to say.

View solution in original post

3 Replies
Or
MVP
MVP

What sort of increment are you looking to use, exactly?

If your list of values isn't too long, you could just use ValueList(). Otherwise, you'd probably want to generate the values in your script using a loop.

AmCh
Creator
Creator
Author

My list of values is too long.
Basically, a non-decimal incrementing is possible with do while loop. How can I then create a list with this loop in the script?

Many thanks in advance.

Or
MVP
MVP

Set vValue = 10;

for i=1 to 99

Set vValue = vValue + pi()/e();  /* Your increment goes in this line*/

Load $(vValue) as SyntheticDimension

Autogenerate(1);

next

 

You could probably do this more efficiently with just autogenerate and the row number, but since I'm not sure exactly what sort of increment you're trying to work with, it's hard to say.