Measure works in Excel PP - but not in PowerBI

smaur

New Member
Joined
May 17, 2007
Messages
17
Hi All,
I have a fact table of 'events' with a dates of occurrence for each event and other data about the events. In PowerPivot I have a measure to count the number of occurrences of events between two dates as filtered by a Date Slicer. The measure relies on the UseRelationship function because I need to have the relationship between fact table and date table normally inactive.

Here is that measure:
TotalEvents:=Calculate(COUNTROWS(fProdStop),USERELATIONSHIP(DCalendar[Date],fProdStop[FromDate]))

This works fine in Excel. The problem is I can't get it to work in Power BI. My resulting bar chart for the event count plotted against the month on the x axis shows only one bar, with the word (blank) beneath the bar. The value plotted on that one bar is the total number of events for every month in one lump sum.

Any ideas of what is happening here?
 

Excel Facts

Workdays for a market open Mon, Wed, Friday?
Yes! Use "0101011" for the weekend argument in NETWORKDAYS.INTL or WORKDAY.INTL. The 7 digits start on Monday. 1 means it is a weekend.
Check the connection type in PowerBI between your tables. They me be set to bidirectional which could mess up your results.
 
Upvote 0

Forum statistics

Threads
1,223,674
Messages
6,173,746
Members
452,533
Latest member
Alex19k

We've detected that you are using an adblocker.

We have a great community of people providing Excel help here, but the hosting costs are enormous. You can help keep this site running by allowing ads on MrExcel.com.
Allow Ads at MrExcel

Which adblocker are you using?

Disable AdBlock

Follow these easy steps to disable AdBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the icon in the browser’s toolbar.
2)Click on the "Pause on this site" option.
Go back

Disable AdBlock Plus

Follow these easy steps to disable AdBlock Plus

1)Click on the icon in the browser’s toolbar.
2)Click on the toggle to disable it for "mrexcel.com".
Go back

Disable uBlock Origin

Follow these easy steps to disable uBlock Origin

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back

Disable uBlock

Follow these easy steps to disable uBlock

1)Click on the icon in the browser’s toolbar.
2)Click on the "Power" button.
3)Click on the "Refresh" button.
Go back
Back
Top