Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Dear Experts:
Here is the requirement from my client.
They want to update a report monthly where the columns of a table will be generated and named dynamically based on a calculation.
For example, in the sales table they will have the following columns
The report will show the following
In the report
1. The first column will show the products which has some changes in sales against "Sales Today".
2. Only those months will be shown where there is changes in sales
Here, for Product "A" there is change (1 unit) against 3rd previous month.
for Product "B" there are changes in sales against 1st and 3rd month.
for Product "C" there are changes in sales against 1st and 3rd month.
But there is no changes in sales against 2nd month - as a result the report didn't show anything like "Change against 2nd month"
Seeking your opinions to achieve this requirement.
Sample data is attached.
Shafi
Try this:
Hi Ahammad,
Apply following expression:
Dimension :- Product
Expression1:Change against 1st month:- [Sales last month]-[Sales Today]
Expression2:Change against 3rd month:- [Sales Today]-[Sales 3 months back]
From above you will get following reselt
Product | Change against 1st month | Change against 3rd month |
---|---|---|
A | 0 | 1 |
B | 2 | 3 |
C | -1 | 5 |
Thanks,
Hey I am correcting my above expressions:
Dimension :- Product
Expression1:Change against 1st month:- [Sales Today]-[Sales last month]
Expression2:Change against 3rd month:- [Sales Today]-[Sales 3 months back]
From above you will get following result
Product | Change against 1st month | Change against 3rd month |
---|---|---|
A | 0 | 1 |
B | -2 | 3 |
C | 1 | 5 |
Thanks,
Till Report, i am happy. After that, i am not sure i understand your rek. Would you share the epected result to show
conditional Hide/Show
Chart Straight table,
Dim - Product, today Sales
Expression - 1. [Sales last month]-[Sales Today]
2. [Sales 2 months back]-[Sales Today]
3. [Sales 3 months back]-[Sales Today]
PRESENTATION -
Conditional show/hide --- for exp 2: if(sum(total([Sales 2 months back]-[Sales Today]))=0,0,1)
and so on for others
Oh! It is current - last month
So just make the change in the formula:
Like:
[Sales Today]-[Sales last month]
[Sales Today]-[Sales 2 months back]
[Sales Today]-[Sales 3 months back]
PRESENTATION -
Conditional show/hide --- for exp 2: if(sum(total([Sales Today]-[Sales 2 months back]))=0,0,1)
and so on for others
I hope this helps!
Hi All:
Many thanks for your replies.
Sorry that I missed one point - it is not fixed that client will want to show the difference only for 3 months. The number of months could vary; like it can be 4 months or 5 months or 2 months. It will depend on the input data they will provide.
Hi Anil:
Please let me rephrase the requirement in words.
In input data the the client will share today's sales and sales of few previous months (the number of months can vary - like it can have 1 month or 2 months or 3 months.... or 9 months).
In the report we have to show the difference in sales with previous months. No columns will be shown if there is no difference with a month.
In the given example there are sales of previous 3 months, but tomorrow they can share input data with only 2 previous months. So, tomorrow the number of columns in the table should decrease.
Please let me know if that helps.
Shafi
Hi Varsha:
Many thanks.
Sorry that I missed one requirement. The number of expression will vary based on the number of months given in input data. In next refresh the client may give 4 previous months data or 5.
Shafi
ahh!
Okay, no problem.
Can you please tell me how you get this data from your client ?
Just like in excel i.e this month, last month , last 2 month
or in proper months like 112016, 102016 etc.