Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hello,
I would like to cound customernumbers that meet certain criterias.
I will Count all customernumbers where the customer has sum(DebPris)>30000
and where the sum is bigger this month than the previous mont. It´s the part I
have marked with bold text I cannot get running.
count({$<$(vSetMTD),[Segment]={"Glas"},[KundNr]={"=Sum([DebPris])>=30000"},
{Sum({$<$(vSetMTD),[Segment]={"Glas"},[KundNr]={"=Sum([DebPris])>=30000"}>} [DebPris]) >
Sum({$<$(vSetPreviousMonth),[Segment]={"Glas"},[KundNr]={"=Sum([DebPris])>=30000"}>} [DebPris])}
>} Distinct(KundNr))
kindly
Håkan
I believe it can be achieved in the charts as follows:
if(Sum({$<$(vSetMTD),[Segment]={"Glas"}>} [DebPris]) > 30000 AND Sum({$<$(vSetMTD),[Segment]={"Glas"}>} [DebPris])>Sum({$<$(vSetPreviousMonth),[Segment]={"Glas"}>} [DebPris]),count({$<$(vSetMTD),[Segment]={"Glas"}>} Distinct KundNr))
If possible the simplest and most efficient method would be to create flags for each of these requirements in the script. Then reference them in the Set Analysis.
Can you upload a sample app?
Here comes an test app
Håkan
I believe it can be achieved in the charts as follows:
if(Sum({$<$(vSetMTD),[Segment]={"Glas"}>} [DebPris]) > 30000 AND Sum({$<$(vSetMTD),[Segment]={"Glas"}>} [DebPris])>Sum({$<$(vSetPreviousMonth),[Segment]={"Glas"}>} [DebPris]),count({$<$(vSetMTD),[Segment]={"Glas"}>} Distinct KundNr))