Skip to main content
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

If then condition Qlik Sense

Hello -

I have a simple Oracle table which I pulled into Qlik Sense. the columns are structured as below:

VERSIONMONTHAMOUNT
ACTUALJAN100
ACTUALFEB200
PLANJAN80
PLANMAR90

In Qlik Sense I am trying to use a table and create a measure for Actual as a column and one for the plan using if condition in a measure calculation. This is how I want to see it:

VERSIONMONTHACTUALPLAN
ACTUALJAN10080
ACTUALFEB2000
PLANMAR90

I am using the following calculation under 'measure' in Qlik Sense:

if (VERSION_ID='ACTUAL', Sum(AMOUNT), 0) for the Actual column and

if (VERSION_ID='PLAN', Sum(AMOUNT), 0) FOR PLAN column but

I don't get any numbers calculating. What am I missing? Please help.

Thanks!!

1 Solution

Accepted Solutions
lironbaram
Partner - Master III
Partner - Master III

first

try to change to

sum(if (VERSION_ID='ACTUAL', AMOUNT, 0) )

sum(if (VERSION_ID='PLAN', AMOUNT, 0) )



View solution in original post

9 Replies
lironbaram
Partner - Master III
Partner - Master III

first

try to change to

sum(if (VERSION_ID='ACTUAL', AMOUNT, 0) )

sum(if (VERSION_ID='PLAN', AMOUNT, 0) )



Not applicable
Author

Thank you!!! That worked Thank you so much.

MarcoWedel

Hi,

you could also use a generic load in the script to create the table you described.

hope this helps

regards

Marco

MarcoWedel

In QlikView it could look like:

QlikCommunity_Thread_145658_Pic1.JPG

Generic

LOAD MONTH,

    VERSION,

    AMOUNT

FROM [http://community.qlik.com/thread/145658] (html, codepage is 1252, embedded labels, table is @1);

hope this helps

regards

Marco

MarcoWedel

and in Qlik Sense:

QlikCommunity_Thread_145658_Pic1.JPG

Generic LOAD

     MONTH,

     VERSION,

     AMOUNT

FROM [lib://QlikCommunity_Thread_145658] (html, codepage is 1252, embedded labels, table is @1);

QlikCommunity_Thread_145658_Pic2.JPG

hope this helps

regards

Marco

Not applicable
Author

Marco -

This works! Thank you so much for the help.

MarcoWedel

You're welcome.

If you like , you can mark helpful in case it helped you.

Thanks

Regards

Marco

Not applicable
Author

I looked to mark it helpful but can't find it. Can you please let me know how to mark the response helpful?

Thanks!!

MarcoWedel

Hi,

when logged in, there should be this button available in your threads:

_Helpful.JPG

regards

Marco