Forum Discussion

Anonymous's avatar
Anonymous
Not applicable
5 years ago

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.

 

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

 
 
 
 
 

 

 

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

  • Anonymous's avatar
    Anonymous
    Not applicable

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

    • Anonymous's avatar
      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 

       

       

  • vapid128's avatar
    vapid128
    Solution Specialist

     

     

     

     

    Or you can do in dax.

     

    Create Table:

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

     

     

     

     

    Or you can do in dax.

     

    Create Table:

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