Forum Discussion
Anonymous
3 years agoNot applicable
Subtract 1 day from a date
Hi!
I have a problem with a conditional formula, I need that if the validated field is equal to zero, it brings me the invoice date field.1, but if it is <> zero (that is, -1) it subtracts one day from the invoice date field.1 .
The error is when you must subtract a day, since I am subtracting a numerical data from a date format. What is the correct way to subtract a day from the date format?
Thanks.
Anonymous In DAX you can just use -1 but what you are showing is Power Query and in that case you need to use Date.AddDays function.
1 Reply
- Greg_Deckler
Community Champion
Anonymous In DAX you can just use -1 but what you are showing is Power Query and in that case you need to use Date.AddDays function.