Skip to main content

IF({Sale Date}="",(DATETIME_DIFF({Sale Date},{Purchase Date},‘d’), (DATETIME_DIFF({Today’s Date},Purchase Date},‘d’))

I miss 2 closing parentheses, from the DATETIME_DIFF. Also the second {Purchase Date} has no opening bracket.


I miss 2 closing parentheses, from the DATETIME_DIFF. Also the second {Purchase Date} has no opening bracket.


Didn’t work, but I found an alternate solution. It accepted my Datetime_diff if it were the 3rd item in the if statement, but not the second one.


I don’t understand your last message, but I’ve created a simpler formula that works:


IF(Sale, DATETIME_DIFF( Sale, Purchase,'d'),DATETIME_DIFF( TODAY(),Purchase,'d')).


You can see my table: https://airtable.com/shrM7rGbN4msFSGPT



  • You don’t need to wrap the DATETIME_DIFF function

  • You don’t need a field for Today, as you have TODAY() function

  • You don’t need to make = ""with the Sale Date

  • Recommendation: field names with just one word, so you don’t need the {}:

    • Just Sale, as it’s a Date field

    • Join words as SaleDate

    • Separate words with an underscore: Sale_Date.




I don’t understand your last message, but I’ve created a simpler formula that works:


IF(Sale, DATETIME_DIFF( Sale, Purchase,'d'),DATETIME_DIFF( TODAY(),Purchase,'d')).


You can see my table: https://airtable.com/shrM7rGbN4msFSGPT



  • You don’t need to wrap the DATETIME_DIFF function

  • You don’t need a field for Today, as you have TODAY() function

  • You don’t need to make = ""with the Sale Date

  • Recommendation: field names with just one word, so you don’t need the {}:

    • Just Sale, as it’s a Date field

    • Join words as SaleDate

    • Separate words with an underscore: Sale_Date.




Thank you for the help!