Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
hello
i have a table like this:
id | month | d day | F Sr Net Sales Amount |
---|---|---|---|
1 | 1 | 25 | 5000 |
2 | 1 | 26 | 200 |
3 | 2 | 3 | 600 |
4 | 2 | 7 | 2500 |
5 | 2 | 9 | 2000 |
user asks to show him the last day sale in the month selected
i scripted like this< but it has some errors:
Sum ({< [d Day]= MaxString ([d Day]) >} [F Sr Net Sales Amount])
Try:
Sum ({< [d Day]= {"$(=Max([d Day]))"} >} [F Sr Net Sales Amount])
Try:
Sum ({< [d Day]= {"$(=Max([d Day]))"} >} [F Sr Net Sales Amount])
Try this:
Sum ({< [d Day]= {'$(=Max([d Day]))'} >} [F Sr Net Sales Amount])
Try below
Sum ({< [d Day]= {'$(=Max([d Day]))'} >} [F Sr Net Sales Amount])
Regards
ASHFAQ
Create a straight table
Dimension
month
expression
=FirstSortedValue(DISTINCT Aggr(SUM([F Sr Net Sales Amount]),month,[d day]),-[d day])
You will have a syntex error for above expression, but just ignore it... You will have your answer...
Hi Manish ,
Your Solution in working fine. I also tried solving it using this expression
=Sum({<[d day]={'=Aggr(Max([d day]),month)'}>}[F Sr Net Sales Amount])
But it is giving the incorrect Result
Answer is Like
Month , Sales
1 , 5000
2 , 600
I am not able find , why Result is coming like this
Thanks and Regards,
Vivek
thank you,
well what would it be if i want this as the condition:
d Day <= A
"A" is something i get as the input
Try below
Sum ({< [d Day]= {'<=$(=Date(Max([d Day])))'} >} [F Sr Net Sales Amount])
Regards
ASHFAQ