Find answers, ask questions, and connect with our
community around the world.

TM1 Explorers: Explore, Challenge and Summit with TM1 Base Camp Forums TM1 Technical Rules Using an Element in a Rule with Inverted Comma in Element

  • Using an Element in a Rule with Inverted Comma in Element

    Posted by Sarah on 15-Apr-21 at 4:02 pm

    Hi guys,

    Does anyone know how to use an element in a rule that has a single inverted comma in the element name? For example, the rule below has a single inverted comma in “Worker’s Comp”. If I try using that, the rule fails to save because it reads the “r’s” as the end of the string. My rule is:

    ['Forecast','Worker's Comp'] = N: ['Salary Plus'] * DB('Forecast Assumptions',!Year,!Version,'Worker's Comp %');

    Thanks for your help,

    Sarah

    John replied 3 years, 5 months ago 2 Members · 1 Reply
  • 1 Reply
  • John

    Administrator
    15-Apr-21 at 4:08 pm
    2 Diamonds
    14 Gold
    2,230 Experience
    Hiker

    Hiya Sarah,

    I did this just the other day. If you replace the single inverted comma with two sequential inverted commas, then the Rule will save. So you rule would look like this:

    ['Forecast','Worker''s Comp'] = N: ['Salary Plus'] * DB('Forecast Assumptions',!Year,!Version,'Worker''s Comp %');

    This works in TI’s too.

    Thanks

    John

Log in to reply.