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

calculating measure based on value of dimension

I am working with the below data

DateSales (Thousands)

 

01/04/2017
02/04/2017
03/04/2017
04/04/2017
05/04/2017
06/04/2017
07/04/2017
08/04/2017
09/04/2017
10/04/2017
11/04/2017
12/04/2017
13/04/2017
14/04/2017
15/04/2017
16/04/2017
17/04/2017
18/04/2017
19/04/2017
20/04/2017
21/04/2017
22/04/2017
23/04/2017
24/04/2017
25/04/2017
26/04/2017
27/04/2017
28/04/2017
29/04/2017
30/04/2017

 

82
81
63
51
11
20
60
80
99
67
64
29
1
60
83
60
92
90
83
26
7
84
13
82
93
98
50
49
31
49

I need to calculate the ratio of sales on first day of month to sales on last day of month. I am trying to display this in a KPI box but dont understand what expression to use. All help greatly appreciated.

2 Replies
ahaahaaha
Partner - Master
Partner - Master

Hi,

As variant for your data in attached file.

Regards,

Andrey

OmarBenSalem

Suppose you have :

load

Date, Sales

from source;

You'll just have to create Month of Year field:

LOAD *, Month(Date)&'-'&Year(Date) as MonthYear;

load

Date, Sales

from source;

Than, in your chart, choose as a Dimension: MonthYear

As a measure: Sum(Sales)