Qlik Community

QlikView Scripting

Discussion Board for collaboration on QlikView Scripting.

QlikView Fans! We’d love to hear from you.
Share your QlikView feedback with the product team… Click here to participate in our 5-minute survey.
Rules, plus terms and conditions, can be found here.
Not applicable

Choose connection string based on computer name

I have a connection string that works on one pc, but not on the other, and vice versa..

So two connection strings.

What I want to do is have an if satement that checks the computer name, and if its computer A, then use connection 1, else use connection 2.

How do I do this?

Tags (1)
1 Reply

Choose connection string based on computer name


just do it like this:

if ComputerName() = 'COMPUTER_A' then

     CONNECT DB1....;

elseif ComputerName() = 'COMPUTER_B' then

     CONNECT DB2....;


     exit script;

end if

- Ralf

Community Browser