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

Register now to learn Fabric in free live sessions led by the best Microsoft experts. From Apr 16 to May 9, in English and Spanish.

Reply
ovetteabejuela
Impactful Individual
Impactful Individual

Use Date Dimension to Supply Missing Days

Hi Community!,

 

I'd like to know how to accomplish this using DAX,

 

The table on the left has some missing dates, I'd like to use my Date dimension to supply it with the missing dates resulting to the table on the right.

 

Supply Missing Dates.PNG

 

I'm excited about the solution, always impressed what DAX can do and the person giving out the solution! =).

 

SAMPLE DATA:

DateEmployeeData
1/1/2017Ann Filch401
1/2/2017Ann Filch773
1/3/2017Ann Filch875
1/6/2017Ann Filch274
1/7/2017Ann Filch953
1/8/2017Ann Filch186
1/9/2017Ann Filch494
1/10/2017Ann Filch408
1/11/2017Ann Filch266
1/12/2017Ann Filch636
1/13/2017Ann Filch406
1/15/2017Ann Filch814
1/16/2017Ann Filch944
1/17/2017Ann Filch774
1/18/2017Ann Filch834
1/19/2017Ann Filch167
1/21/2017Ann Filch796
1/22/2017Ann Filch838
1/23/2017Ann Filch854
1/24/2017Ann Filch779

 

Thanks in advance!

 

1 ACCEPTED SOLUTION

Hi @ovetteabejuela,


You can add a calculate column to deal with this, for example :

 

Repaced= if ([Column]=blank(),[Value Column],[Column])

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

View solution in original post

6 REPLIES 6
Habib
Responsive Resident
Responsive Resident

Hi @ovetteabejuela, you can use  function to achieve this.

 

NewTable = NATURALLEFTOUTERJOIN(DateDim,EmployeeData)

 

I am asuming you have Date Dimension as DateDim, and the sample data iwth EmployeeData. Make sure that your column names are different in both tables as this is limitation in current verison of the formula.

 

Here is the output.

3-10-2017 1-55-19 AM.png

 

 

 

 

Thanks @Habib, partly solved my problem, is there a way we can include the Employee Name as well in the resulting Table? I see that the Name is missing.

Employee name is part of BI the result table. Please refer to screenshot of my previous post.

I was wanting to have those names appear in the 1/4, 1/5, 1/14 and 1/20 - though I think it is possible I just don't know exactly how.

Hi @ovetteabejuela,


You can add a calculate column to deal with this, for example :

 

Repaced= if ([Column]=blank(),[Value Column],[Column])

 

Regards,

Xiaoxin Sheng

Community Support Team _ Xiaoxin
If this post helps, please consider accept as solution to help other members find it more quickly.

@v-shex-msft, haven't actually tried but I can see that this could actually work. Thanks!

Helpful resources

Announcements
Microsoft Fabric Learn Together

Microsoft Fabric Learn Together

Covering the world! 9:00-10:30 AM Sydney, 4:00-5:30 PM CET (Paris/Berlin), 7:00-8:30 PM Mexico City

PBI_APRIL_CAROUSEL1

Power BI Monthly Update - April 2024

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

April Fabric Community Update

Fabric Community Update - April 2024

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