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

Announcements
Posting on Qlik Community is temporarily paused for some users. Thank you for patience and we'll update you soon!
cancel
Showing results for 
Search instead for 
Did you mean: 
Anonymous
Not applicable

if...else in formula

Hi,

is it's possible to use if...else in formula?

sum ( { <value1= { 'a' }, value2 = { 'b' }>} eur)

sum ( { <value1 = { 'a' }, value2 = { if (value3 = 2,'b','c' } >)


Regards

Stefan

Labels (1)
5 Replies
sujeetsingh
Master III
Master III

Stefen please explain what you want by this expression

Anonymous
Not applicable
Author

In my formula value2 should have b or c.

Not applicable
Author

hi Stefan,

i don't think that if...else can use internal set analisis,

if...else  is an alternative the set analisis:

sum(if...)

Regards

tresB
Champion III
Champion III

Try something like:

sum ( { <value1 = { 'a' }, value2 = { " $(=if (value3 = 2,'b','c')) "} >} eur)

senpradip007
Specialist III
Specialist III

Hi Stefan

evaluate if( value3 = 2, 'b', 'c') in a variable let say x.

now try this

Sum({< value1 = {'a'}, value2 = {$(x)} >} eur)