March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount! Early bird discount ends December 31.
Register NowBe one of the first to start using Fabric Databases. View on-demand sessions with database experts and the Microsoft product team to learn just how easy it is to get started. Watch now
Hi,
I have a Fact table.
This is connected to a DimDate with the Date field, working great..
... and also connected to a lot of other Dim tables, working great..
I have connected my Fact to DimTable1 -> DimTable2 -> DimTable3 -> DimTable4.
On DimTable4 I want to count how many there is where Type=1, Type=2 etc..
I have a COUNTROWS(DimTable4) in my Fact, and filtering on the type. No matter what I do, it only shows me the total amount of rows.
What do I have to change, and why?
Thanks in advance.
@krimyr see below:
If I filter on the Fact column that has relationship to DimTable1, it wont affect the result. this will not, since fact table doesn't filter dimension table. There are ways to work with this but with your current relationship it will not.
If I filter on the DimTable1 column that has relationship to DimTable2, it wont affect the result. If dim table1 has relationship dim table 2 (1 to many) then it should work. Can you share relationship diagram?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
CountDimRows = COUNTROWS(DimTable4)
DimTalbe2[Name] as ROWS
DimTable4[Type] as COLUMNS
CountDimRows as VALUES
Shows as I want it.
If I filter on the Fact column that has relationship to DimTable1, it wont affect the result.
If I filter on the DimTable1 column that has relationship to DimTable2, it wont affect the result.
If I filter on the DimTable2 column that has relationship to DimTable3, it does affect the result as it should.
Why is that?
It seems that there's relationships missing, but its connected, and I can't see the problem.
You are right, now it works. I have been working on this too many hours. I of course must have done something different. Thanks
@krimyr if you create a measure that countrows from dimtable4 and you visualize using type (from same table), it should give the result you are looking for or maybe I'm missing something.
Count = COUNTROWS ( DimTable4 )
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
@krimyr your presentation seems confusing, I guess dim tables doesn't have a relationship with each other?
Which table has the type column?
Subscribe to the @PowerBIHowTo YT channel for an upcoming video on List and Record functions in Power Query!!
Learn Power BI and Fabric - subscribe to our YT channel - Click here: @PowerBIHowTo
If my solution proved useful, I'd be delighted to receive Kudos. When you put effort into asking a question, it's equally thoughtful to acknowledge and give Kudos to the individual who helped you solve the problem. It's a small gesture that shows appreciation and encouragement! ❤
Did I answer your question? Mark my post as a solution. Proud to be a Super User! Appreciate your Kudos 🙂
Feel free to email me with any of your BI needs.
I am sorry! I thought it was clear.
Fact has a relationship to DimTable1. (1 to many)
DimTable1 has a relationship to DimTable2 (1 to many)
DimTable2 has a relationship to DimTable3 (1 to many)
DimTable3 has a relationship to DimTable4 (1 to many)
DimTable4 has Type which I want to count based on Type=1,2,3 etc.
March 31 - April 2, 2025, in Las Vegas, Nevada. Use code MSCUST for a $150 discount!
Your insights matter. That’s why we created a quick survey to learn about your experience finding answers to technical questions.
Arun Ulag shares exciting details about the Microsoft Fabric Conference 2025, which will be held in Las Vegas, NV.
User | Count |
---|---|
133 | |
90 | |
88 | |
64 | |
58 |
User | Count |
---|---|
203 | |
141 | |
107 | |
73 | |
70 |