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

Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now

Reply
bourne2000
Helper V
Helper V

My date table is not working,

Hi

 

I have sales table which comes from database. It starts from 2012. My sales table as follow

 

bourne2000_0-1635465089148.png

 

I have created a date table as follow

 

bourne2000_1-1635465111633.png

 

I connected the date table and sales table through date. I am trying to create a table by dragging Month from date table and sales from sales table. However, I am getting below empty one

 

bourne2000_2-1635465187792.png

 

 

Can anyone advise please?

 

Here is the sample pbix file https://we.tl/t-rARbRR4HEO

 

1 ACCEPTED SOLUTION
Ashish_Mathur
Super User
Super User

Hi,

In the Query Editor, seperate the date and time into 2 columns.  Then create a Calendar Table from the Date column.  Create a relationship from the Date column of the data table to the Date column of the Calendar Table.  In the Calendar table, extract Year, Month name and Month number using calculated column formulas.  Sort the Month name by the month number.  To your visual, drag Year and month name from the Calendar Table.

Hope this helps. 


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/

View solution in original post

4 REPLIES 4
Ashish_Mathur
Super User
Super User

Hi,

In the Query Editor, seperate the date and time into 2 columns.  Then create a Calendar Table from the Date column.  Create a relationship from the Date column of the data table to the Date column of the Calendar Table.  In the Calendar table, extract Year, Month name and Month number using calculated column formulas.  Sort the Month name by the month number.  To your visual, drag Year and month name from the Calendar Table.

Hope this helps. 


Regards,
Ashish Mathur
http://www.ashishmathur.com
https://www.linkedin.com/in/excelenthusiasts/
HotChilli
Super User
Super User

You probably created the date as a copy of the Sales[Date] column and changed the datatype.  Seems sensible but doesn't work.

Try

newcol = DATE(YEAR(Sales[Date]), MONTH(Sales[Date]), DAY((Sales[Date])))

 

 

HotChilli
Super User
Super User

I haven't looked at the file but it will almost certainly be the dates not matching because they have times in the Fact table.  So create another column in the Fact table which is just the date (without time) and use that in the relationship.

Let me know how you get on 

@HotChilli No It's still the same

Helpful resources

Announcements
November Power BI Update Carousel

Power BI Monthly Update - November 2025

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

Fabric Data Days Carousel

Fabric Data Days

Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!

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.

Top Solution Authors