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

Announcements
Join us to spark ideas for how to put the latest capabilities into action. Register here!
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

For loop

Hi Friends,

How can we fetch data from different environments(Dev,Test,Prod) by using for loops? It will be very help if any example or document about this

Thank you,

SatishRaj

1 Reply
Qrishna
Master
Master

I never tried using for loops for this kind of  scenario, but yes you can write an if() statement something like below.

If Environment = 'PRO' Then

CONNECT TO [....]

Else

CONNECT TO [...]

End If

wrap it up in a text file.rename the extension with .qvs

Include this file in your script.

$(Must_Include=..\_data source\connectionstring.qvs); or $(Include=..\_data source\connectionstring.qvs);

Hope that helps.