cancel
Showing results for 
Search instead for 
Did you mean: 
Reply
Highlighted
Advocate I
Advocate I

Allocating Values Over Time Based on Initial Date

I have two tables -

One with Assignment Volume designated by an Assignment Number.

The other table breaks out the Assignments by how many months they take and how much time is allocated per month. 

Tables shown below. 

 

I need a way to assign the Start Month in Table 1 to "Month in Assignment" =1 for that particular assignment type, and the subsequent months for that assignment. 

I need to create a calendar that shows how much time per month is needed based on the information I have.  I have been stumped for a week on this. Any advice?

 

Assignment_Table.PNGTime_Table.PNG

1 ACCEPTED SOLUTION

Accepted Solutions
Highlighted
Microsoft
Microsoft

Re: Allocating Values Over Time Based on Initial Date

Hi @prill2ta,

 

Since there isn't a month "February" for "A-100-101", I would suggest you create a new table. Please check out the demo in the attachment.

Table =
SELECTCOLUMNS (
    ADDCOLUMNS (
        FILTER (
            CROSSJOIN (
                SELECTCOLUMNS (
                    'Table1',
                    "a", [Assignment Type],
                    "b", [Designator],
                    "c", [Start Month]
                ),
                Table2
            ),
            [a] = [Assignment Type]
        ),
        "startmonth", EDATE ( [c], [Month in Assignment] - 1 )
    ),
    "Designator", [b],
    "Assignment Type", [a],
    "Month in Assignment", [Month in Assignment],
    "Time Dedication (hrs)", [Time Dedication (hrs)],
    "Final StartMonth", [startmonth]
)

Allocating-Values-Over-Time-Based-on-Initial-Date

 

Best Regards,
Dale

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

View solution in original post

4 REPLIES 4
Highlighted
Super User IV
Super User IV

Re: Allocating Values Over Time Based on Initial Date

So are those tables related?


---------------------------------------

Putting square pegs in round holes since 1972.

I have a NEW book! 
DAX Cookbook from Packt
Over 120 DAX Recipes!




Did I answer your question? Mark my post as a solution!

Proud to be a Super User!




Highlighted
Advocate I
Advocate I

Re: Allocating Values Over Time Based on Initial Date

Hey Greg!

 

In this "nerfed down" instance of my particular issue, yes. 

 

These are related by the Assignment Type. 


I am able to currently calculate a total time needed per assignment with no issues.  The main problem I am having is assigning the Start Date of the Assignment to Month in Assignment = 1. 

 

For example: 

 

Assignment Designator "A-100-101" has Start Month = "1/1/2016" and Assignment Type = "1"

I can see from the Time Table that Assignment Type = "1" has a duration of 4 months ("1", "2", "3", "4"), and each month has a different time requirement. 

 

I am looking to be able to say that for "A-100-101" January 2016 =1.25 hrs, Feburary = 1hrs, March = 0.5hrs, and April = 1.5hrs based on the second table. 

Highlighted
Microsoft
Microsoft

Re: Allocating Values Over Time Based on Initial Date

Hi @prill2ta,

 

Since there isn't a month "February" for "A-100-101", I would suggest you create a new table. Please check out the demo in the attachment.

Table =
SELECTCOLUMNS (
    ADDCOLUMNS (
        FILTER (
            CROSSJOIN (
                SELECTCOLUMNS (
                    'Table1',
                    "a", [Assignment Type],
                    "b", [Designator],
                    "c", [Start Month]
                ),
                Table2
            ),
            [a] = [Assignment Type]
        ),
        "startmonth", EDATE ( [c], [Month in Assignment] - 1 )
    ),
    "Designator", [b],
    "Assignment Type", [a],
    "Month in Assignment", [Month in Assignment],
    "Time Dedication (hrs)", [Time Dedication (hrs)],
    "Final StartMonth", [startmonth]
)

Allocating-Values-Over-Time-Based-on-Initial-Date

 

Best Regards,
Dale

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

View solution in original post

Highlighted
Advocate I
Advocate I

Re: Allocating Values Over Time Based on Initial Date

Hey @v-jiascu-msft

 

Thank you very much. This is the solution I have been looking for. 

 

I will be sure to study this to ensure that I completely understand what's going on!

Helpful resources

Announcements
Super Users of the Quarter - Q2 2020

Super Users of the Quarter - Q2 2020

Who are our Super User Superstars? Who made it to the top of the leaderboards? Get the answers!

June 2020 Community Highlights

June 2020 Community Highlights

Featured community members, changes to the Community, and more! Read up on recent Power BI community news.

Community Summit North America

Community Summit North America

Innovate, Collaborate, Grow. The top training and networking event across the globe for Microsoft Business Applications

Power Platform 2020 release wave 2 plan

Power Platform 2020 release wave 2 plan

Features releasing from October 2020 through March 2021

Top Kudoed Authors