Forum Discussion

ShannonMcFarlin's avatar
ShannonMcFarlin
Qrew Trainee
8 years ago

syntax error

Syntax error for Max([Referral Date],[2nd Referral Date],[3rd Referral Date]) If(<[Most Recent Referral Date], null)

We are trying to leave a field blank if it is less than the "most recent referral date"field. This formula works for our max value between referral dates, but not for the If statement 

4 Replies

  • ChrisChris's avatar
    ChrisChris
    Qrew Assistant Captain

    if(

    max([referral date],[2nd referral date],[3rd referral date])<[most recent referral date],null, {else?}

    )

  • Thank you for such a quick response! 

    That did not work.

    First I copied and pasted your code as you sent it, it did not work. I ended up with the following:

    Max([Referral Date],[2nd Referral Date],[3rd Referral Date])
    If(
    Max([referral date],[2nd referral date],[3rd referral date])<[most recent referral date],null,{else?})

    It keeps giving me the following error: "There are extra characters beyond the end of the formula"

       
  • ChrisChris's avatar
    ChrisChris
    Qrew Assistant Captain

    Hi,

    The {else?} was a message to you to provide an else condition.

    If you do not have an else condition, remove the , {else?} including that comma before the left brace, so that the code says, .... date],null )