Ansicht
Dokumentation

ABENREGEX_XSD_SYNTAX - REGEX XSD SYNTAX

ABENREGEX_XSD_SYNTAX - REGEX XSD SYNTAX

BAL_S_LOG - Application Log: Log header data   General Data in Customer Master  
This documentation is copyright by SAP AG.
SAP E-Book

- XSD Syntax

Objects for XSD regular expressions can be created with the factory method CREATE_XSD of the system class CL_ABAP_REGEX to be used in statements FIND and REPLACE or with the system class CL_ABAP_MATCHER.

Currently, there is no detailed description of the XSD syntax for regular expressions in the ABAP keyword documentation.

  • For a short syntax overview, see
Special Characters in XSD Regular Expressions
  • For the complete documentation, please refer to
Regular expressions in XSD 1.0 and 1.1.

Notes

  • A regular expression with XSD syntax cannot be specified directly as a character string in the statements FIND and REPLACE, but you can use objects of CL_ABAP_REGEX that are created with method CREATE_XSD with the addition REGEX instead.
  • XSD Syntax is a subset of XPath syntax. There are mainly the following differences:
  • In a XSD regular expression, ^ and $ are not special characters for start and end of a line.

  • There is no XSD syntax for non-greedy behavior.

  • There is no XSD syntax for subgroups without registration

  • There is no XSD syntax for back references

  • The test and demonstration program DEMO_REGEX allows XSD syntax to be tested by selecting XSD.

The following example uses XSD syntax that is invalid for PCRE and does not find any matches for POSIX. It would work also for XPath. The regular expression contains special characters \i and \c that match any character that can be the first character of an XML name or any character that can occur after the first character of an XML name. The result of the replacement is <ns:tag1><ns:tag2>...</ns:tag2></ns:tag1>.






RFUMSV00 - Advance Return for Tax on Sales/Purchases   SUBST_MERGE_LIST - merge external lists to one complete list with #if... logic for R3up  
This documentation is copyright by SAP AG.

Length: 3444 Date: 20240426 Time: 062313     sap01-206 ( 47 ms )