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
everyrichrole
Frequent Visitor

Date Relationship Problem

I have a problem with something that seems like it should be very simple. I have a Dates table initially generated by AUTOCALENDAR() and also a Consumables table with ID and Dates Used columns. When I try to relate the Date Used in the Consumables table to the Date field in the Dates table, I am unable to get a count by date in the report view. See pictures.

 

 

relationships.pngtable.png

1 ACCEPTED SOLUTION

Unfortunately, I can't release the PBIX without also giving out a bit too much information about our data sources. I can tell you that I tried creating a new calculated column in the Consumables table with =DATEVALUE(Date Used), and I was able to get the relationship working by using that column. So I suspect this may be an internal bug with the date type/format casting of the Date Used column.

View solution in original post

8 REPLIES 8
RMDNA
Solution Sage
Solution Sage

Hi @everyrichrole,

 

It would be helpful to have a picture of your data, but my first steps would be to set both of your date fields to the Date or DateTime type, and make sure they're in the same format (e.g. both DD/MM/YYYY, etc.).

Thanks for your reply, @RMDNA. Those are the first things I tried. Here's a couple pics of the data.

 

dates.png

 

consumables.png

 

 

 

Hmm, your dates don't look out of alignment. Could you share your PBIX via dropbox/onedrive/etc.?

Unfortunately, I can't release the PBIX without also giving out a bit too much information about our data sources. I can tell you that I tried creating a new calculated column in the Consumables table with =DATEVALUE(Date Used), and I was able to get the relationship working by using that column. So I suspect this may be an internal bug with the date type/format casting of the Date Used column.

Thank you! That solved my Problem too! 🙂

Anonymous
Not applicable

Thanks a lot, this solution worked for me as well, Before using this solution i wasted almost 5/7 hours but not able to reach the desired results with RELATED function output, finally got this solution and it worked 🙂

I had the same problem, DATEVALUE solution works nicely, what worked for me also was changing data type during import from date/time to date only.

 

Maybe someone will find this useful.

 

Best regards

Glad to hear it's fixed! Go ahead and mark your own comment as the solution.

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.