Qlik Community

New to Qlik Sense

Discussion board where members can get started with Qlik Sense.

kjcnagel
New Contributor II

Formula within set analysis

Hi all,

i'm new to the Forum and very excited about QlikView.

Currently I have a Problem with using a formula within a set Analysis.

With disctinct data it Looks like this:

= num(
sum(
{<
Kalender.Datum = {"31.03.2017"}
>}
YE_WE_PosFAU.E_WE_LieferMenge)
, '###.##0')

This spits out the right result!

But if I ask like this:

= num(
sum(
{< Kalender.Datum = {$(max(YE_WE_PosFAU.PrüfDatum,3))}
>}
YE_WE_PosFAU.E_WE_LieferMenge)
, '###.##0')

it doesn't return the right numbers.

I have checked, and

=max(YE_WE_PosFAU.PrüfDatum,3))
is the 31.03.2017

Why is it, that the formula won't be calculated correctly?

Thank you in advance.

Kevin


1 Solution

Accepted Solutions
MVP
MVP

Re: Formula within set analysis

Try this

=Num(Sum({< Kalender.Datum = {"$(=Max(YE_WE_PosFAU.PrüfDatum,3))"}>} YE_WE_PosFAU.E_WE_LieferMenge), '###.##0')

6 Replies
MVP
MVP

Re: Formula within set analysis

Try this

=Num(Sum({< Kalender.Datum = {"$(=Max(YE_WE_PosFAU.PrüfDatum,3))"}>} YE_WE_PosFAU.E_WE_LieferMenge), '###.##0')

Re: Formula within set analysis

try this

num(

sum(

{< Kalender.Datum = {"$(=max(YE_WE_PosFAU.PrüfDatum,3)))"}

>}

YE_WE_PosFAU.E_WE_LieferMenge)

, '###.##0')

MVP
MVP

Re: Formula within set analysis

Or this

=Num(Sum({< Kalender.Datum = {"$(=Date(Max(YE_WE_PosFAU.PrüfDatum,3), 'DD.MM.YYYY'))"}>} YE_WE_PosFAU.E_WE_LieferMenge), '###.##0')

MVP
MVP

Re: Formula within set analysis

See also

Dollar-sign expansion using an expression ‒ Qlik Sense

Dates in Set Analysis

Also note that the dollar sign expansion is evaluated in global or total context, not per dimensional value.

kjcnagel
New Contributor II

Re: Formula within set analysis

Thanks a lot, this worked!

Have a good day

kjcnagel
New Contributor II

Re: Formula within set analysis

thank you!

It is the same solution as is the one by Mr Talwar. I guess yours has one too many brackets within the set Analysis. But if corrected, it worked out.

Thanks again!