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

Don't miss out! 2025 Microsoft Fabric Community Conference, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount. Prices go up February 11th. Register now.

Reply
Anonymous
Not applicable

Fill dates between two dates

I have a employee table with  employee number,country, joined date and reasigned date as shown in the below image. There are employees from three countries.

 

Chandimal_Mara_0-1606205112489.png

I'm also maintaining the workingdays relavent to each country in the Date table in the boolean format

 
 
 
 
 

Capture1.JPG

 

 

My requirement is to create a new table to fill the working days from the date of join and date of resign as one by one records on the table. *country also should be considered when filling the dates becuase correct workingday columns should be selected corresponsding to employees country. 

 

 

 

 

 

 

 

 

 

 

 

 

 

6 REPLIES 6
vapid128
Solution Specialist
Solution Specialist

image.pngimage.pngimage.png

 

image.pngimage.png

 

 

 

Or you can do in dax.

 

Create Table:

image.png

Table 2 = GENERATE('Table',GENERATESERIES(int('Table'[DateStart]),INT('Table'[DateEnd])))
vapid128
Solution Specialist
Solution Specialist

image.pngimage.pngimage.png

 

image.pngimage.png

 

 

 

Or you can do in dax.

 

Create Table:

image.png

Table 2 = GENERATE('Table',GENERATESERIES(int('Table'[DateStart]),INT('Table'[DateEnd])))
Divergence_One
New Member

Check-out these instructions to determine which of the two solutions will work best for you. Both solutions posted here are industry best.

amitchandak
Super User
Super User

@Anonymous , Refer to the file attached if that can help. Please refer the Table

 

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

The requirements are not entirely clear. Could you please give an example of the output?

Anonymous
Not applicable

This is the expected outcome. dates column depicts the workingdays between joined date and resigned date. Inorder to get the workingdays of the employee, date table has to be checked for the workingdays for each country.  Availibility is just a column with 1 value to make the visulization easir on a matrix 

 

Chandimal_Mara_0-1606220473923.png

 

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 MSCUST for a $150 discount! Prices go up Feb. 11th.

Jan25PBI_Carousel

Power BI Monthly Update - January 2025

Check out the January 2025 Power BI update to learn about new features in Reporting, Modeling, and Data Connectivity.

Jan NL Carousel

Fabric Community Update - January 2025

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