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

Line chart expression

Hi All,

I am developing line chart in my application,my requirement is current month sales in 1 line, last month sales is 2nd line and lastyear same month is 3rd line.

I taken date as a dimension.how can i write the expression for representing this three lines in chart.

can anyone having idea of this.thanks in advance..

regards,

baru

3 Replies
whiteline
Master II
Master II

Use set analysis in your expresions.

Not applicable
Author

Hi Whiteline,

Thanks for your reply,

can i have one example for this 3 expressions

regards,

baru

whiteline
Master II
Master II

I can give you only a general example as I don't know you fields name, data and all of your requrements.

It strongly depends on how you handle dates, date formats and so on.

=Sum({$<Month={"=Month=Month(Today())"}>} Sales)

=Sum({$<Month={"=Month=Month(Today())-1"}>} Sales)

=Sum({$<Month={"=Month=Month(Today())-1"}, Year={"=Year=Year(Today())-1"}>} Sales) 

The above expressions will work only if you have month as number and year as number.

There is a plenty of examples in help (search set analysis).