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

Get inspired! Check out the entries from the Power BI DataViz World Championships preliminary rounds and give kudos to your favorites. View the vizzies.

Reply
kwil
Regular Visitor

Relationship with date table showing no data

Hi, I feel like I've searched everywhere and just can't find the solution to my issue here. 

I am trying to make a relationship between a table I made with DirectQuery from a local SQL server and a Date Table that I made with CALENDARAUTO, and I need to make a visual that shows TotalExtended by month. However, when I try to make a visual it returns no data, like so:

kwil_0-1680795964615.png

I set the relationship between DateAdded and Date, and it seems to be an incomplete relationship for some reason but I'm not sure if this matters.

kwil_1-1680796034492.png

Another thing that I think may be the cause is that in the "edit relationship" window it only shows three rows, and the rows it shows are not actually related.

kwil_2-1680796145704.png

Our data in the table technically goes back to 2015, but I have in the WHERE clause of the DirectQuery to only return data from the past 12 months, so I'm not sure if this could also be causing problems.

 

If anyone has any ideas I would be very grateful, thank you!

1 ACCEPTED SOLUTION
amitchandak
Super User
Super User

@kwil , A date joining with date of the date table should not have a timestamp. So you should bring a date from DB not having timestamp for join

 

Also consider date table using calendar function if needed

 

Why Time Intelligence Fails - Powerbi 5 Savior Steps for TI :https://youtu.be/OBf0rjpp5Hw
https://amitchandak.medium.com/power-bi-5-key-points-to-make-time-intelligence-successful-bd52912a5b...
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

View solution in original post

3 REPLIES 3
amitchandak
Super User
Super User

@kwil , A date joining with date of the date table should not have a timestamp. So you should bring a date from DB not having timestamp for join

 

Also consider date table using calendar function if needed

 

Why Time Intelligence Fails - Powerbi 5 Savior Steps for TI :https://youtu.be/OBf0rjpp5Hw
https://amitchandak.medium.com/power-bi-5-key-points-to-make-time-intelligence-successful-bd52912a5b...
To get the best of the time intelligence function. Make sure you have a date calendar and it has been marked as the date in model view. Also, join it with the date column of your fact/s. Refer :radacad sqlbi My Video Series Appreciate your Kudos.

Full Power BI Video 20 Hours YouTube
Microsoft Fabric Series 60+ Videos YouTube
Microsoft Fabric Hindi End to End YouTube

I tried removing the timestamp by changing the format to just "Date" instead of "Date/Time" but it didn't seem to do anything.

kwil
Regular Visitor

Nevermind, I had to go into the SQL statement and cast my dates to remove the timestamp from there. Thank you!

Helpful resources

Announcements
Las Vegas 2025

Join us at the Microsoft Fabric Community Conference

March 31 - April 2, 2025, in Las Vegas, Nevada. Use code FABINSIDER for a $400 discount!

FebPBI_Carousel

Power BI Monthly Update - February 2025

Check out the February 2025 Power BI update to learn about new features.

March2025 Carousel

Fabric Community Update - March 2025

Find out what's new and trending in the Fabric community.

Top Kudoed Authors