Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

Conditional "total"

Hi all,

My QVW file is attached.

In the file you'll see that only the 2nd order has the value of "subTitle".

The requirement is that if the field "subTitle" has value, then show the partial sums, otherwise, don't show the partial sums.

Can and how the QlikView archieve this requirement?

Thanks and best regards,

CoCo

1 Solution

Accepted Solutions
NareshGuntur
Partner - Specialist
Partner - Specialist

I have done the samething in the attached qvw(in the below reply)

LOAD * Inline [

Test

subTitle

Total

];

In Dimension, in place of subTitle(3rd dimension), use

=if(Test = 'subTitle', subTitle, if(Len(subTitle)>0, Test))

View solution in original post

16 Replies
Not applicable
Author

There is no attachment to this thread. Can you re-attach your file.

Not applicable
Author

Oh, Sorry!

Please have a look at the attachment.

Thanks.

NareshGuntur
Partner - Specialist
Partner - Specialist

Hi CoCo,

As you are using Personal Edition, I 'll not share the qvw but you can add this script.

LOAD * Inline [

Test

subTitle

Total

];

In Dimension, in place of subTitle(3rd dimension), use

=if(Test = 'subTitle', subTitle, if(Len(subTitle)>0, Test))

Cheers,

Naresh

Not applicable
Author

Hello,

Thanks for your kind help. I tried but it didn't achieve the need.

The requirement is when the field "subTitle" has value, then calculate the partial sum.

When the field "subTitle" is null, ie, the corresponding order has only one row, then do nothing.

So how can I do? Please help me.

Best regards,

CoCo

NareshGuntur
Partner - Specialist
Partner - Specialist

You can have a look at the attached qvw.

Cheers,

Naresh

NareshGuntur
Partner - Specialist
Partner - Specialist

You need something like this if I am not wrong.

QVPlayGround2.jpg

Not applicable
Author

Yes, right. That's just what I want.

NareshGuntur
Partner - Specialist
Partner - Specialist

I have done the samething in the attached qvw(in the below reply)

LOAD * Inline [

Test

subTitle

Total

];

In Dimension, in place of subTitle(3rd dimension), use

=if(Test = 'subTitle', subTitle, if(Len(subTitle)>0, Test))

Not applicable
Author

Oh dear, you know I'm using the Personal Edition, can't open the attached qvw file.