Skip to Content

Complex Table search and set as initial value

All,

I have a requirement to search for a value ending with 'N' in a complex table. If the count of values ending with 'N' is more than 1, user to select the value from Complex table search drop down. If CT has only one value ending with 'N' then I need to set as initial value which is ending with N. I looked into RFind function which gives a sub string. How do i do it using a Regular expression using JavaScript.

Sample values in CT

Condition 1, More values ending with N. User will select from Complex table.

ACCOON

LWDXNN

LWDXNO

LWTXNN

Condition 2, only 1 value is ending with N, which should be defaulted in transaction screen.

LWDXNN

LWDXNO

Request to guide in achieving this.

Thanks in advance.

Add comment
10|10000 characters needed characters exceeded

  • Get RSS Feed

1 Answer

  • Nov 28, 2017 at 02:14 AM

    Given that this will require looping over every row and checking the last character which is not ideal from a performance standpoint I would recommend modifying the complex table to include an extra column with the last character so you can index on that new column and more efficiently determine the answer to your question.

    --Bill

    Add comment
    10|10000 characters needed characters exceeded

    • Thanks Bill for your reply.

      The suggested change by adding an additional column to CT is not feasible as this is part of User performance improvement process and will be considered.

      At this point I only want to check if the last character is ending with N, could you please let me know the possible way to achieve. we are considering only Agentry level changes for the fix.

      Regards,

      Ashwin