cancel
Showing results for 
Search instead for 
Did you mean: 

Fabric is Generally Available. Browse Fabric Presentations. Work towards your Fabric certification with the Cloud Skills Challenge.

Reply
DPatkos
Helper I
Helper I

Can a date slicer with inactive relationship filter on table and return values with no aggregation?

Hi,

I have a DateTable and InfoTable (example below) where the 2 have an active relationship on StartDate and an inactive relationshiop on EndDate.

IDStartDateEndDateType
User12022-01-012022-01-01a
User22022-01-012022-01-05b
User32022-01-012022-01-05c
User42022-01-052022-01-04a
User52022-01-052022-01-07b

 

I'd like to have a simple table visualization which interacts with a slicer. The slicer is coming from the Date table but using the inactive relationship of the DateTable.

I'm already using USERELATIONSHIP where possible, but I cannot get my head around in case of the ID column, where I'd like to return all the values with said criteria without any aggregation.

 

For example:

If I select 2022-01-05 on the slicer I'd like to see only User2 User3 in my visual and not User4 or User5.

Is there a way to achieve this without duplicating the date table (which I would try to avoid) or making the active relationship inactive too (which I would also try to avoid) .

Thanks in advance!

1 ACCEPTED SOLUTION
SivaMani
Resident Rockstar
Resident Rockstar

@DPatkos , Create a measure,

Count of Id = Calculate(COUNT(Table[Id]), USERLATIONSHIP(Date[Date], Table[EndDate]))

Add this measure as a visual level filter in the table visual and Apply Count of Id >= 1.

View solution in original post

4 REPLIES 4
DPatkos
Helper I
Helper I

Thanks @SivaMani ,

 

I've tried this previously and the issue is that it only returns one small part of the data and not all the rows. Any idea why?

thanks

@DPatkos,

 

If I select 2022-01-05 on the slicer I'd like to see only User2 & User3 in my visual and not User4 or User5.

The proposed approach will meet the above requirement. Verify the other filters and make sure no conflicts. 

You are right, it had a conflict with another filter. Thanks agani!

SivaMani
Resident Rockstar
Resident Rockstar

@DPatkos , Create a measure,

Count of Id = Calculate(COUNT(Table[Id]), USERLATIONSHIP(Date[Date], Table[EndDate]))

Add this measure as a visual level filter in the table visual and Apply Count of Id >= 1.

Helpful resources

Announcements
PBI November 2023 Update Carousel

Power BI Monthly Update - November 2023

Check out the November 2023 Power BI update to learn about new features.

Community News

Fabric Community News unified experience

Read the latest Fabric Community announcements, including updates on Power BI, Synapse, Data Factory and Data Activator.

Power BI Fabric Summit Carousel

The largest Power BI and Fabric virtual conference

130+ sessions, 130+ speakers, Product managers, MVPs, and experts. All about Power BI and Fabric. Attend online or watch the recordings.

Top Solution Authors
Top Kudoed Authors