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

Ignore selections on dimension

Hi All,

I have data from January 2015 to April 2016

I have created a line chart with different months and want to show all the months available irrespective of any selection except Year.

Dimesnsion : Month

Expression : If(Isnull(1-(Column1/Column2)),1,(1-(Column1/Column2)))

Case 1: If I select Year as 2015, I want to show all months(Jan - Dec) irrespective of any selection

Case 2 : If I select Year as 2016, I want to show only 4 Months (Jan - April) irrespective of any selection

on the dimension.

PS : Show all values will fail for Case 2 as it will show all the months and not only 4.

Also, there are no values for some Month - Year. Where it should display 1 as per the expression.

Regards,

Anjali Gupta

1 Solution

Accepted Solutions
Digvijay_Singh

I think this is what you want, see the attached one -

View solution in original post

28 Replies
sunny_talwar

What are your expressions for Column2 and Column2? Would you be able to share a sample?

vikramv
Creator III
Creator III

12.jpg

Try this option on Month

Not applicable
Author

No Sunny, I can't share the sample because of security purpose and also its connected to different mapping sheets. So, might be confusing.

Regards,

Anjali Gupta

Not applicable
Author

Hi Vikram,

As mentioned earlier, Show All values is showing all the months for Case 2 i.e. on selection of year 2016.

Regards,

Anjali Gupta

sunny_talwar

I guess I am unable to completely understand what you are wanting to do. That is why I was hoping for few rows of sample dummy data with the expected output on the chart.

vikramv
Creator III
Creator III

Are you looking for something like this :

Sample Expression :

if( GetFieldSelections(Year) = '2016',sum({$<Month ={1,2,3,4}>} Sales),Sum(Sales))

if( GetFieldSelections(Year) = '2016',Sum({$<Month ={'January','February','March','April'}>} Sales),Sum(Sales))

Not applicable
Author

Hi Sunny,

Say i have 2 fields in a mapping table

Field1Field2

A

AA
BBB
CCC
DDD
EEE
FFF
GGG
HHH
III
JJJ
KKK
LLL

Then I have a data table

with few Columns and Field2

Say

UniqueIDDateColumn1Column2Field2
110-01-2015451400AA
223-06-2015346400DD
306-03-2016243400HH
417-08-2015253540DD
518-11-2015454534CC
627-01-2016235675HH
728-04-2016454500BB

With the Dates, I can say I have data from Jan-2015 to April 2016.

For all selection of Field1  [this is from mapping table] (Always One Selected) from a listbox, I want to show a trend (Line chart) for all the months.

If no data then 1 else 1-(Coulmn1/Column2) .

When i have checked Show All Values , the case 2 failed as mentioned above and shown data for May-2016 to December-2016. Which are future dates or data is yet to be received by me.

Hope this can make you help me..!!

Regards,

Anjali Gupta

Not applicable
Author

Hi Vikram, Thanks for the quick response. But Is there any way to restrict it in the dimension itself ?

Regards,

Anjali Gupta

vikramv
Creator III
Creator III

Creat a dummy dimension for month and use

if( GetFieldSelections(Year) = '2016' and Match(Month,1,2,3,4), Dummy Dimension,Original Dimension)