Formula

Hi

I am using an action button to speed up our sales team, I would like to be able to name the opportunity as part of the action button based on fields in the account, this is where I am at the moment:

equal( (related($accounts, "coefss_c", " ") "Review", related($accounts, "review_due_c" " "), 2024) I was hoping this would return this e.g,

COE Review Nov 2024

Any help much appreciated.

Joe 

Parents
  • Hi  ,

    The equal() formula in SugarLogic is a boolean formula which means it only returns a value of true or false. The formula you are seeking would be concat(). Your formula would look like this:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    concat(
    related(
    $accounts,
    "coefss_c"
    ),
    " Review ",
    related(
    $accounts,
    "review_due_c"
    ),
    " 2024"
    )
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Hardcoding a year in the formula may not produce the desired results. If your 'review_due_c' is a month dropdown and they select 'January', you may want that to say 'January 2025' (or whatever the next year is when this action is taken). If that's a potential use case, I recommend reviewing ways you could automate the year in that formula rather than hardcoding it. 

    Chris

Reply
  • Hi  ,

    The equal() formula in SugarLogic is a boolean formula which means it only returns a value of true or false. The formula you are seeking would be concat(). Your formula would look like this:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    concat(
    related(
    $accounts,
    "coefss_c"
    ),
    " Review ",
    related(
    $accounts,
    "review_due_c"
    ),
    " 2024"
    )
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Hardcoding a year in the formula may not produce the desired results. If your 'review_due_c' is a month dropdown and they select 'January', you may want that to say 'January 2025' (or whatever the next year is when this action is taken). If that's a potential use case, I recommend reviewing ways you could automate the year in that formula rather than hardcoding it. 

    Chris

Children
  • HI Chris

    Thanks for taking the time to look at this for me, the formula above currently returns Review2024, the two related fields are dropdowns, but I am trying to get the displayed values from the individual accounts, is this why we are getting this return.

    joe