Skip to main content
Announcements
Live today at 11 AM ET. Get your questions about Qlik Connect answered, or just listen in. SIGN UP NOW
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

if, if else statement for load scripts

Tryin to load this statement in load scripts...

 

if (Group=='B009') {'CONSOLIDATED INSURERS'} else if (Group=='T107') {'THE CONTINENTAL GROUP'} else {Account_Name}

 

7 Replies
Not applicable
Author

Try following:

if (Group=='B009','CONSOLIDATED INSURERS',if (Group=='T107', 'THE CONTINENTAL GROUP', 'Account_Name')) as Name

Anonymous
Not applicable
Author

Hello Tom,

Try this:

IF(Group=B009,[CONSOLIDATED INSURERS], if (Group=T107 ,['THE CONTINENTAL GROUP] , [Account_Name]))


Regards

Jacek

vishsaggi
Champion III
Champion III

Using Jacek expression may be use quotes around the Group values like

if (Group = 'B009', 'CONSOLIDATED INSURERS',

if (Group = 'T107', 'THE CONTINENTAL GROUP', 'Account_Name')) as Name

vishsaggi
Champion III
Champion III

Did you get what you looking for?

Anonymous
Not applicable
Author

Yes I did...Thank you very much

vishsaggi
Champion III
Champion III

Can you close the thread marking appropriate responses as correct or Helpful.

Thanks
V.

omkarvamsi
Creator
Creator

Hi,


please try below script


if (Group='B009', 'CONSOLIDATED INSURERS',

     if (Group='T107','THE CONTINENTAL GROUP','Account_Name') as ALIASNAME


Note:

if Account_Name is a field it should not be enclosed in the single quotations.

Only strings are to be placed in between in singular quotations.


Regards

Om