Please help to see why this formula returns 1 instead of 0?

IFTRIM(Deliverable Item) <> TRIM('DAT.040 Approved Deliverables'.Deliverable Item[LOOKUP: 'SYS.910 Other Settings'.Audit Version Lookup])THEN 1ELSE 0

Deliverable Item is :Channel Data Mgmt Platform: Pre-study to build one single harmonized platform for all our Partner data, expanding our capability to deliver data driven insights  ;

'DAT.040 Approved Deliverables'.Deliverable Item[LOOKUP: 'SYS.910 Other Settings'.Audit Version Lookup]) is:

Channel Data Mgmt Platform: Pre-study to build one single harmonized platform for all our Partner data, expanding our capability to deliver data driven insights;

Best Answer

Answers

  • @licx13

    It appears there is a space before the semicolon in first expression.

    regards,

    vinayvm

  • @vinayvm

    Yes, there are indeed spaces in the first expression, but I used the trim function for comparison. Why didn't I remove the spaces?

  • @licx13 ,

    The trim function removes leading and trailing spaces, and any extra spaces between words (replaces with single space char). So, there would still remain a diff between the two texts you are comparing. Therefore, it is returning the right result.

    Here is the detail about trim function:

    https://help.anaplan.com/trim-351955a5-838c-4f3b-9073-96732fc259a9

    Perhaps, you might want to try this function with shorter texts just for clarity.

    regards,

    vinayvm

  • If necessary, how can I compare long texts with only the last few spaces left?Is there a way to remove the last blank space?

    thanks

  • Is it possible to compare after ignoring semicolon/last character… To ignore semicolon you can get length of character and use left function -1….After removing semicolon you can use the trim formula which you're using currently

    V.Sai Bharadwaj

    Connect on LinkedIn

  • The problem now is that the last char of this long text is a space. I tried to use the trim function to remove it, but it was unsuccessful.

    Text is :

    "Channel Data Mgmt Platform: Pre-study to build one single harmonized platform for all our Partner data, expanding our capability to deliver data driven insights  "

    Need help

  • can you please share screenshot of your formulas

    V.Sai Bharadwaj

    Connect on LinkedIn

  • licx13
    edited July 2023

    *Resource Name is:

    “Channel Data Mgmt Platform: Pre-study to build one single harmonized platform for all our Partner data, expanding our capability to deliver data driven insights ”

    trim *Resource Name still is:

    “Channel Data Mgmt Platform: Pre-study to build one single harmonized platform for all our Partner data, expanding our capability to deliver data driven insights ”

    why?