Unknown field "assigned to"

Good morning,

I'm still working on the formula around the "Assigned to" and this field really giving me trouble.

So i want a field to indicate "1" if the case is assigned to X.
I wrote : 

ifElse(equal(related($assigned_user_link,"assigned_user_name"),"Yves Bourgarel"),"1","2")

But it is telling me "related: Unknown Field : assigned_user_name"

Whe i inspect the page, assigned_user_name definitaly seems to be the name of the field. I'm not sure if i should have a "related" function before, but even without it, i have the same problem.

Any ideas ?

thank you

Parents
  • Hi  ,

    assigned_user_name is not a valid field to use for the purposes of Sugar Logic formulas, you could do something like the following:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    12
    13
    14
    15
    16
    17
    ifElse(
    equal(
    concat(
    related(
    $assigned_user_link,
    "first_name"
    ),
    related(
    $assigned_user_link,
    "last_name"
    )
    ),
    "YvesBourgarel"
    ),
    "1",
    "2"
    )
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    An alternative I do for a lot of our clients is to create a custom text field in the Users module which represents their full name with the following formula:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    concat(
    related(
    $assigned_user_link,
    "first_name"
    ),
    " ",
    related(
    $assigned_user_link,
    "last_name"
    )
    )
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    I find this custom field useful for grouping in summation & matrix reports (as opposed to grouping by user name) as well as simplifying formulas like the one for your use case. Your formula would then look like:

    Fullscreen
    1
    2
    3
    4
    5
    6
    7
    8
    9
    10
    11
    ifElse(
    equal(
    related(
    $assigned_user_link,
    "full_name_c"
    ),
    "Yves Bourgarel"
    ),
    "1",
    "2"
    )
    XXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXXX

    Chris

  • Oh strange... i deleted my initial question, because i found the answer a few minutes later :) 
    and i indeed used this to resolve the problem :

    related(
    $assigned_user_link,
    "first_name"

    thanks tho Slight smile

Reply
  • Oh strange... i deleted my initial question, because i found the answer a few minutes later :) 
    and i indeed used this to resolve the problem :

    related(
    $assigned_user_link,
    "first_name"

    thanks tho Slight smile

Children
No Data