Power BI is turning 10, and we’re marking the occasion with a special community challenge. Use your creativity to tell a story, uncover trends, or highlight something unexpected.
Get startedJoin us for an expert-led overview of the tools and concepts you'll need to become a Certified Power BI Data Analyst and pass exam PL-300. Register now.
Hi
I want to create the same formula in power bi from Excel. But not too sure how to achieve this. the main formula used in Excel in column to DUE is =IF([@PromiseDt]=0,"Uncommitted",[@PromiseDt]-MAX(TODAY(),[@DueDate]))
DueDate | PromiseDt | to Due |
27-Jan-22 | Uncommitted | |
01-Feb-22 | 22-Apr-2022 | -5 |
17-Apr-22 | 06-May-2022 | 9 |
08-Aug-22 | 08-Aug-22 | 0 |
12-Oct-22 | 27-Apr-2022 | -168 |
17-Apr-22 | 8-May-2022 | 21 |
07-Jun-22 | 12-Jul-2022 | 35 |
12-Jul-22 | 12-Jul-22 | 0 |
Solved! Go to Solution.
Hi @drgrd13
you may Create a new Column
To Due =
IF (
ISBLANK ( Table[PromiseDt] ),
"Uncommitted",
DATEDIFF ( Table[PromiseDt], MAX ( TODAY (), Table[DueDate] ), DAY )
)
Thank you for the help but the formula is resulting in an error msg as below
Yes this is not allowed. You can retun blank
To Due = IF ( NOT ISBLANK ( Table[PromiseDt] ), DATEDIFF ( Table[PromiseDt], MAX ( TODAY (), Table[DueDate] ), DAY ) )
Or otherwise, you can return the date as string.
Hi @drgrd13
you may Create a new Column
To Due =
IF (
ISBLANK ( Table[PromiseDt] ),
"Uncommitted",
DATEDIFF ( Table[PromiseDt], MAX ( TODAY (), Table[DueDate] ), DAY )
)
User | Count |
---|---|
14 | |
9 | |
7 | |
7 | |
6 |
User | Count |
---|---|
21 | |
11 | |
10 | |
10 | |
8 |