Microsoft Fabric Community Conference 2025, March 31 - April 2, Las Vegas, Nevada. Use code MSCUST for a $150 discount.
Register nowThe Power BI DataViz World Championships are on! With four chances to enter, you could win a spot in the LIVE Grand Finale in Las Vegas. Show off your skills.
Hello,
Trying to figure out this error
Trying to figure out days between current date and request date for items that do not have a finish date, getting an expression error We cannot apply field access to the type Function.
Details:
Value=[Function]
Key=Current Date
This is my current expression
if [#"Finish Date #(lf)"]= null then Duration.Days[Current Date]-[Request Date] else 0
Thanks in Advance
Solved! Go to Solution.
Hi @Brash1 ,
Try something like this:
if [#"Finish Date #(lf)"] = null
then Duration.Days(Date.From(DateTime.LocalNow()) - [Request Date])
else 0
Pete
Proud to be a Datanaut!
Thanks Pete, I think this solution worked.
Brilliant! Glad that's worked for you.
Don't forget to give a thumbs-up on any posts that have helped you 👍
Pete
Proud to be a Datanaut!
Hi @Brash1 ,
Try something like this:
if [#"Finish Date #(lf)"] = null
then Duration.Days(Date.From(DateTime.LocalNow()) - [Request Date])
else 0
Pete
Proud to be a Datanaut!
User | Count |
---|---|
19 | |
10 | |
10 | |
9 | |
7 |