Join us at FabCon Atlanta from March 16 - 20, 2026, for the ultimate Fabric, Power BI, AI and SQL community-led event. Save $200 with code FABCOMM.
Register now!Get Fabric Certified for FREE during Fabric Data Days. Don't miss your chance! Request now
I wotld like to calculate new date base on duration day(duration come form another caluateion) from start date. and stiwh on somedate which are not in the list of table 2
table 1
| Team | start date | Duration day | New date |
| A | 22-Feb-21 | 2 | 24-Feb-21( swith 23-Feb) |
| A | 22-Feb-21 | 1 | 22-Feb-21 |
| B | 22-Feb-21 | 3 | 24-Feb-21 |
Table 2
| Team | work day |
| A | 22-Feb-21 |
| A | 24-Feb-21 |
| A | 25-Feb-21 |
| B | 22-Feb-21 |
| B | 23-Feb-21 |
| B | 24-Feb-21 |
How calulate "New date" column in table 1 by swicth the date if it is not in the list of each team from table2
Solved! Go to Solution.
Hi @Anonymous ,
Try this:
Column =
VAR t =
FILTER ( 'Table 2', 'Table 2'[Team] = EARLIER ( 'Table 1'[Team] ) )
VAR NewDate = [start date] + [Duration day] - 1
VAR ModifiedNewDate =
MINX ( FILTER ( t, [work day] >= NewDate ), [work day] )
RETURN
ModifiedNewDate
Measure =
VAR NewDate =
MAX ( [start date] ) + MAX ( [Duration day] ) - 1
VAR ModifiedNewDate =
MINX ( FILTER ( 'Table 2', [work day] >= NewDate ), [work day] )
RETURN
ModifiedNewDate
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Hi @Anonymous ,
Try this:
Column =
VAR t =
FILTER ( 'Table 2', 'Table 2'[Team] = EARLIER ( 'Table 1'[Team] ) )
VAR NewDate = [start date] + [Duration day] - 1
VAR ModifiedNewDate =
MINX ( FILTER ( t, [work day] >= NewDate ), [work day] )
RETURN
ModifiedNewDate
Measure =
VAR NewDate =
MAX ( [start date] ) + MAX ( [Duration day] ) - 1
VAR ModifiedNewDate =
MINX ( FILTER ( 'Table 2', [work day] >= NewDate ), [work day] )
RETURN
ModifiedNewDate
Best Regards,
Icey
If this post helps, then please consider Accept it as the solution to help the other members find it more quickly.
Not able to understand the question. Go through this: https://community.powerbi.com/t5/Desktop/How-to-Get-Your-Question-Answered-Quickly/m-p/1447523#M6071...
Check out the November 2025 Power BI update to learn about new features.
Advance your Data & AI career with 50 days of live learning, contests, hands-on challenges, study groups & certifications and more!
| User | Count |
|---|---|
| 101 | |
| 76 | |
| 56 | |
| 51 | |
| 46 |