Skip to Content

In SAP Abap CDS, how to do ltrim and implement fuzzy search

I want to do fuzzy search on a field which has leading zeroes, so need to first ltrim the zeroes and implement the fuzzy search. Can anyone help me out on this?

Add a comment
10|10000 characters needed characters exceeded

Related questions

1 Answer

  • Posted on Jul 14, 2020 at 03:55 AM

    Hello Kishor Kumar,

    There are different approaches for the same as mentioned below:

    1) You can Use LTRIM Functionality as shown below

       ltrim( matnr, '0' ) as Mat_Output,  

    2) You can try using ABAP CDS cast expressions follow the examples in the LINK for better understanding.

    3) You can always use the AMDP concepts, try using CDS with table functions. This will serve the purpose as it covers wide range of syntaxes.


    Add a comment
    10|10000 characters needed characters exceeded

Before answering

You should only submit an answer when you are proposing a solution to the poster's problem. If you want the poster to clarify the question or provide more information, please leave a comment instead, requesting additional details. When answering, please include specifics, such as step-by-step instructions, context for the solution, and links to useful resources. Also, please make sure that you answer complies with our Rules of Engagement.
You must be Logged in to submit an answer.

Up to 10 attachments (including images) can be used with a maximum of 1.0 MB each and 10.5 MB total.