What kind of “regular expression” system does SAP GUI use in the user interface?
-
15-06-2021 - |
Frage
I'm trying to search the documentation for a data element whose description contains the string '*hh:mm' but not 'mm:ss' (where '' is a wildcard for any number of characters).
I don't know how to do it, so I was wondering if any of you know the regex system SAP GUI uses, so I can have a look at what I can do with it.
Thx, you guys rule!
Lösung
The GUI does not give you the opportunity to use regular expressions. You're limited to a simple pattern matching using *
and ?
. Furthermore, it's a bad idea to search using the description text because the text and the search is case sensitive - you'd find "hh:mm", but not "HH:MM". In the special case you mention, you could use the repository infosystem to search for domains based on the data type TIMS but with an output length of 5 and then use the where-used index to find out a corresponding data element. (It might even be possible to search for a data element based on a certain data type, I'm not entirely sure.)
Andere Tipps
As of release 7.0, ABAP supports extended regular expressions in accordance with POSIX standard 1003.2.
The classes CL_ABAP_REGEX and CL_ABAP_MATCHER permit object-oriented use of regular expressions.
More detail here