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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Rayudu1
Frequent Visitor

How to synchronize the report page and make separate slicers for Day 1 and Day 2 dates

Hello Team,
I have Two tables.
Table 1:How to create different dates (Day1 and Day2) slicers by using below sample data.

Rayudu1_0-1726401407354.png

Please find the wireframe for refrerence.

Rayudu1_1-1726401649915.png

Solution: I am follow the below link: 
https://community.fabric.microsoft.com/t5/DAX-Commands-and-Tips/Total-Sales-from-2-different-dates/m...

Table2:

This is the below columns,

Date-Time , Power and Panels.

How to create different Start Time (Hours, Minutes ) and End Time (Hours, Minutes) Slicers .

Please find the below screenshot for reference and Sample Data:

Rayudu1_2-1726401836834.png

Rayudu1_3-1726402096997.png

 

Solution:
I am follow the below link: 
Solved: Re: How to create Start Time and End Time Slicers ... - Microsoft Fabric Community

This is the full wirefrem

Rayudu1_4-1726402669730.png

 



I am facing the filtering issues:
I am able to filter the data (cards and line chart) after choosing Day 1 (choose Date: August 1, 2024) and
Day 2 is the option I've chosen (choose Date: August 2, 2024). "The line chart data cannot be filtered (We have Legends{Panels}; each date has two lines; however, we are choosing two days' worth of data, so four lines total, but it is only displaying two lines)..
Can you please help me:
How to synchronize the report page and make separate slicers for Day 1 and Day 2 dates .

 

 

 

1 ACCEPTED SOLUTION
v-jtian-msft
Community Support
Community Support

Hi,Greg_Deckler ,thanks for your concern about this issue.

Your answer is excellent!
And I would like to share some additional solutions below.
Hi,@Rayudu1.I am glad to help you.

You can refer to my test below:
In fact I do actual testing of what Greg_Deckler suggests and I hope it helps you.
I created two separate calendar tables .

vjtianmsft_0-1726562929048.pngvjtianmsft_1-1726562935256.png

vjtianmsft_0-1726563303505.png

 

Write the corresponding measure according to the calendar table used by the corresponding slicer, and display it in the same line chart.
You can also see the results in the table.
The two slicers will not interfere with each other and will work on their respective measures in the same visual.
Here is my dax code:

 

Calendar1_SUM = 
VAR _date1=MAX('Calendar_Date1'[Date])

VAR result1=CALCULATE(SUM('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date1)
)
RETURN
result1

 

 

 

Calendar2_SUM = 
VAR _date2=MAX('Calendar_Date2'[Date])

VAR result3=CALCULATE(SUM('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date2)
)
RETURN
result3

 

 

 

Calendar1_AVG = 
VAR _date1=MAX('Calendar_Date1'[Date])

VAR result2=CALCULATE(AVERAGE('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date1)
)
RETURN
result2

 

 

 

Calendar2_AVG = 
VAR _date2=MAX('Calendar_Date2'[Date])

VAR result4=CALCULATE(AVERAGE('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date2)
)
RETURN
result4

 

vjtianmsft_3-1726562974970.png

If your four line plots (corresponding to the MEASURE values) are overlapping because the data is close together or there is a large gap between them, you can try turning on the button:
“Logarithmic scale”.
The purpose of this button is to switch the chart's scale from a linear scale to a logarithmic scale. When you turn this option on, the chart will use the logarithmic scale to display the data. This is useful for displaying data that spans a wide range, as the logarithmic scale compresses the data, making the gaps between the data easier to recognize and analyze.

vjtianmsft_4-1726563203020.png


It is important to note that you need to choose the right program for your situation and write the right measu.The test I provided is for reference only.

I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.

Best Regards,

Carson Jian

 



View solution in original post

5 REPLIES 5
v-jtian-msft
Community Support
Community Support

Hi,Greg_Deckler ,thanks for your concern about this issue.

Your answer is excellent!
And I would like to share some additional solutions below.
Hi,@Rayudu1.I am glad to help you.

You can refer to my test below:
In fact I do actual testing of what Greg_Deckler suggests and I hope it helps you.
I created two separate calendar tables .

vjtianmsft_0-1726562929048.pngvjtianmsft_1-1726562935256.png

vjtianmsft_0-1726563303505.png

 

Write the corresponding measure according to the calendar table used by the corresponding slicer, and display it in the same line chart.
You can also see the results in the table.
The two slicers will not interfere with each other and will work on their respective measures in the same visual.
Here is my dax code:

 

Calendar1_SUM = 
VAR _date1=MAX('Calendar_Date1'[Date])

VAR result1=CALCULATE(SUM('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date1)
)
RETURN
result1

 

 

 

Calendar2_SUM = 
VAR _date2=MAX('Calendar_Date2'[Date])

VAR result3=CALCULATE(SUM('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date2)
)
RETURN
result3

 

 

 

Calendar1_AVG = 
VAR _date1=MAX('Calendar_Date1'[Date])

VAR result2=CALCULATE(AVERAGE('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date1)
)
RETURN
result2

 

 

 

Calendar2_AVG = 
VAR _date2=MAX('Calendar_Date2'[Date])

VAR result4=CALCULATE(AVERAGE('Table'[Power]),FILTER(ALL('Table'),'Table'[Date]<=_date2)
)
RETURN
result4

 

vjtianmsft_3-1726562974970.png

If your four line plots (corresponding to the MEASURE values) are overlapping because the data is close together or there is a large gap between them, you can try turning on the button:
“Logarithmic scale”.
The purpose of this button is to switch the chart's scale from a linear scale to a logarithmic scale. When you turn this option on, the chart will use the logarithmic scale to display the data. This is useful for displaying data that spans a wide range, as the logarithmic scale compresses the data, making the gaps between the data easier to recognize and analyze.

vjtianmsft_4-1726563203020.png


It is important to note that you need to choose the right program for your situation and write the right measu.The test I provided is for reference only.

I hope my suggestions give you good ideas, if you have any more questions, please clarify in a follow-up reply.

Best Regards,

Carson Jian

 



Sorry for delay, Thank you so much and I have accepted your solution but
My requriment is

We have two dates (select date 1 and select different date2 ) but we are unable to sync up with the line chart.
It only syncs up for select date1 only and not Sync up date2.
Kindly check from your end and let us know.
Please find the attached screenshot for your reference.

Rayudu1_1-1726839242892.png

 


 

Hi,@Rayudu1 .Thank you for your support of Power BI.

If you need to implement slicer 1 and slicer 2 to be isolated (not interacting with each other), the fields used by both slicers must not be the same date field / or have a filter relationship between the time fields of both tables.
Also if you want to keep these two fields isolated from each other and make sure that the measures in visual are controlled by slicer1 and slicer2, you have to check if the slicer fields in slicer2 are applied to the measures!
Also for the running logic between the two slicers you mentioned. I don't think there is any relationship between the two slicers according to your description, it's just a comparison of other data at different times between the two of them.
If this is the case, you need to make sure that the date columns used by your slicer1 and slicer2 fulfill the following conditions: the data in both fields is exactly the same, but there is no relationship between these two fields (to avoid interactions).


Which of the following do you mean by synchronization?
1. All the measures in visual are affected by slicer1 and slicer2 at the same time, and the two slicers are passed different time parameters.
2. part of the visual measure is affected by slicer1 and part of the measure is affected by slicer2 (only one of the date fields of the two slicers is used for each measure).

If my understanding is wrong, please correct my misunderstanding and re-describe in detail the problem you encountered and the implementation requirements.
If necessary, please attach a test file that reproduces the problem and a demo of your problem.




Greg_Deckler
Super User
Super User

@Rayudu1 So, in general you do this by using Edit Interactions to control which slicer filters which visuals. I would also recommend that if you are having issues that you consider using 2 disconnected date tables for your slicers and modifying your measures to use the selected value or MAX of those date tables. You can create disconnected date tables easily by doing something like the following:

Date Table 1 = DISTINCT( 'Table'[Date-Time] )


Follow on LinkedIn
@ me in replies or I'll lose your thread!!!
Instead of a Kudo, please vote for this idea
Become an expert!: Enterprise DNA
External Tools: MSHGQM
YouTube Channel!: Microsoft Hates Greg
Latest book!:
Power BI Cookbook Third Edition (Color)

DAX is easy, CALCULATE makes DAX hard...

Thanks for the reply from Greg_Deckler,
Its not filtering data.

Helpful resources

Announcements
Sept PBI Carousel

Power BI Monthly Update - September 2024

Check out the September 2024 Power BI update to learn about new features.

September Hackathon Carousel

Microsoft Fabric & AI Learning Hackathon

Learn from experts, get hands-on experience, and win awesome prizes.

Sept NL Carousel

Fabric Community Update - September 2024

Find out what's new and trending in the Fabric Community.

Top Kudoed Authors