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

Find everything you need to get certified on Fabric—skills challenges, live sessions, exam prep, role guidance, and more. Get started

Reply
Anonymous
Not applicable

Date Table Data Mixup

Hi, 

 

I have created a date table within my report that pulls out the month and year from the given date. 

 

However, when using filters, the data is not being allocated to the specific year:

Untitled.png

The relationship is O-M, and it cross filters both ways. Where am I making the mistake?

 

 

 

5 REPLIES 5
v-yuezhe-msft
Employee
Employee

Hi @Anonymous,

Could you please share sample data of your table and post expected result here?


Thanks,
Lydia Zhang

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Anonymous
Not applicable

help1.pnghelp2.png

 

The 1st is example data. The 2nd is what the table looks like without a dateTable being created. 

 

I want to create a date table, and still achieve these desired results. 

Hi @Anonymous,

The above issue is caused by that you have different DateTime values in the original table, but in your dateTable, I guess that you only have date values or datetime values that only contain 12:00:00. In this scenario, not all the datetime values in your original table match the date values in your dateTable, and you will not get expected result when you drag Year from dateTable.

To solve this issue, create a new column in your original table using the DAX below, make sure that you change date type of the new column in your original table and Date column of dateTable to Date type. Then remove the existing relation between two tables, create a new relationship using this new column and date column in dateTable.

Datecol = DATE(YEAR(Table1[Date]),MONTH(Table1[Date]),DAY(Table1[Date]))
1.PNG

 

Thanks,
Lydia Zhang

Community Support Team _ Lydia Zhang
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.

Hi @v-yuezhe-msft 

So do i need to extract the date for each datetime field in my tables?


What about the possibility to remove the seconds from the datetime table and create a date table with a record for each minute?

Too much data? 

 

Cheers

Anonymous
Not applicable

Helpful resources

Announcements
Fabcon_Europe_Social_Bogo

Europe’s largest Microsoft Fabric Community Conference

Join the community in Stockholm for expert Microsoft Fabric learning including a very exciting keynote from Arun Ulag, Corporate Vice President, Azure Data.

Power BI Carousel June 2024

Power BI Monthly Update - June 2024

Check out the June 2024 Power BI update to learn about new features.

PBI_Carousel_NL_June

Fabric Community Update - June 2024

Get the latest Fabric updates from Build 2024, key Skills Challenge voucher deadlines, top blogs, forum posts, and product ideas.

RTI Forums Carousel3

New forum boards available in Real-Time Intelligence.

Ask questions in Eventhouse and KQL, Eventstream, and Reflex.

Top Solution Authors