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

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now! Learn more

Reply
Bastienlin_
Helper II
Helper II

Dynamical dimension table

Hello,

I have an issue where my dimension table is changing over the years. What I tried to do to deal with it, is to add a date to all my tables so that I can filter the right lines in my dimension table.
My goal is to have a dynamical dimension table that is changing depending on the date.
Here is a sample of my data:
I have no "Orange Juice" in 2022 in my ref_Company because it isn't in our scope anymore, but it is still here in my fact table (Price):
Ref_Company(Dimension table):

Bastienlin__0-1651707225060.png
Price(Fact table):

Bastienlin__1-1651707238845.png
Ref_Date(Dimension table):

Bastienlin__2-1651707224589.png

 

What i expected is that, when I select 2022, when I select 2022we can not see the Orange_index on my visual. But here is what I have:

Bastienlin__3-1651707223765.png

 

It seems that it still manage to get the Orange_Index from 2021 in my Ref_Company. So my ref_Company isn't dynamic.
My goal is to have my Ref_company dynamic depending on the date I select on my slicer.


Do you know how can I deal with this issue ? (Note that I have a lot of facts table like my Price table, so I can not just delete the lines about Orange Juice).
And if you think that my solution about adding a date to my Ref_company isn't a good one, feel free to explain another solution to me.
PBIX file: https://www.dropbox.com/s/t58ujxuo1ppl2bm/Dynamic%20dimension%20table%20depending%20on%20the%20Date....

Thank you very much for your help !

2 REPLIES 2
Anonymous
Not applicable

Hi @Bastienlin_ ,

 

Please firstly make the relationship between Price table and Ref_Date table inactive:

Eyelyn9_1-1652151955093.png

Then create a flag measure:

Flag = 
var _t=SUMMARIZE(FILTER(ALL('Ref_Company'),[Date]=SELECTEDVALUE('Ref_Date'[Date])),[Index])
return IF(MAX('Price'[Index]) in _t && MAX('Price'[Date])=SELECTEDVALUE(Ref_Date[Date])   ,1,0)

And apply it to visual-filter pane, set as "is 1" as shown below:

 

Eyelyn9_0-1652151906589.png

 

Best Regards,
Eyelyn Qin
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

lbendlin
Super User
Super User

Helpful resources

Announcements
Power BI DataViz World Championships

Power BI Dataviz World Championships

The Power BI Data Visualization World Championships is back! Get ahead of the game and start preparing now!

December 2025 Power BI Update Carousel

Power BI Monthly Update - December 2025

Check out the December 2025 Power BI Holiday Recap!

FabCon Atlanta 2026 carousel

FabCon Atlanta 2026

Join us at FabCon Atlanta, March 16-20, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.

Top Solution Authors