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
Arete
Helper I
Helper I

Measure doesn't work when referencing Calendar table fields

Hi All! I have 2 tables, Projects and Calendar, that are linked by the Project's created date. When I create a measure to only include 2022 records it comes back with blank but when I remove it the field property sums:

 

Arete_0-1669140572896.png

CY_Total Budget = 
CALCULATE(
	SUM(Project[Budget__c]),
	'Project'[MPM4_BASE__Status__c] IN { "Open", "Delivered" },
    'Calendar'[Year] IN { 2022 }
)

 

Any help is much appreciated, slowly learning DAX and I'm sure I'm missing something stupid.

1 ACCEPTED SOLUTION
Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your datamodel looks like, but when I see [CreatedDate] column in Project table => I think the data type is Datetime, not date.

I suggest, in power query editor, please change this to Date data type, not datetime data type.

I hope this helps.


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

View solution in original post

2 REPLIES 2
Jihwan_Kim
Super User
Super User

Hi,

I am not sure how your datamodel looks like, but when I see [CreatedDate] column in Project table => I think the data type is Datetime, not date.

I suggest, in power query editor, please change this to Date data type, not datetime data type.

I hope this helps.


If this post helps, then please consider accepting it as the solution to help other members find it faster, and give a big thumbs up.


Click here to visit my LinkedIn page

Click here to schedule a short Teams meeting to discuss your question.

I knew it was something dumb! They are both Date/Time but the time values in the Calendar table are all set to 12:00 so there were no matches. Thanks for the help!

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.