SRET_DOCUMENTS_SEARCH_XML_NEW is a standard SAP function module available within R/3 SAP systems depending on your version and release level. Below is the pattern details for this FM showing its interface including any import and export parameters, exceptions etc as well as any documentation contributions (Comments) specific to the object.
See here to view full function module documentation and code listing, simply by entering the name SRET_DOCUMENTS_SEARCH_XML_NEW into the relevant SAP transaction such as SE37 or SE80.
Associated Function Group:
SRQU
Released Date:
Not Released
Processing type: Remote-Enabled
CALL FUNCTION 'SRET_DOCUMENTS_SEARCH_XML_NEW' "
EXPORTING
catid = " sretidcat-catid
docuspace = " sdokdocsph-docuspace
IMPORTING
numofhits = " sretgstruc-numofhit
rcode = " sretgstruc-rcode
es_errorcode = " sretserrorcode
TABLES
languagetab = " sretlan2
queryparamtab = " sretqatr1
xmlquerytab = " sretqxse
* docattrtab = " sretatr2
resultdoctab = " sretresdoc
* resultattrtab = " sretdcatvl
EXCEPTIONS
CADID_UNKNOWN = 1 "
INTERN_ERROR = 2 "
PARAMETER_ERROR = 3 "
LANGUAGE_ERROR = 4 "
ATTRIBUTE_ERROR = 5 "
RFC_SYS_FAILURE = 6 "
RFC_COM_FAILURE = 7 "
NO_RFC_DEST = 8 "
XERROR = 9 "
. " SRET_DOCUMENTS_SEARCH_XML_NEW
The ABAP code below is a full code listing to execute function module SRET_DOCUMENTS_SEARCH_XML_NEW including all data declarations. The code uses the latest in-line data DECLARATION SYNTAX but I have included an ABAP code snippet at the end to show how declarations would look using the original method of declaring data variables up front. This will allow you to compare and fully understand the new inline method. Please note some of the newer syntax such as the @DATA is not available until a later 4.70 service pack (SP8).
| ld_numofhits | TYPE SRETGSTRUC-NUMOFHIT , |
| ld_rcode | TYPE SRETGSTRUC-RCODE , |
| ld_es_errorcode | TYPE SRETSERRORCODE , |
| it_languagetab | TYPE STANDARD TABLE OF SRETLAN2,"TABLES PARAM |
| wa_languagetab | LIKE LINE OF it_languagetab , |
| it_queryparamtab | TYPE STANDARD TABLE OF SRETQATR1,"TABLES PARAM |
| wa_queryparamtab | LIKE LINE OF it_queryparamtab , |
| it_xmlquerytab | TYPE STANDARD TABLE OF SRETQXSE,"TABLES PARAM |
| wa_xmlquerytab | LIKE LINE OF it_xmlquerytab , |
| it_docattrtab | TYPE STANDARD TABLE OF SRETATR2,"TABLES PARAM |
| wa_docattrtab | LIKE LINE OF it_docattrtab , |
| it_resultdoctab | TYPE STANDARD TABLE OF SRETRESDOC,"TABLES PARAM |
| wa_resultdoctab | LIKE LINE OF it_resultdoctab , |
| it_resultattrtab | TYPE STANDARD TABLE OF SRETDCATVL,"TABLES PARAM |
| wa_resultattrtab | LIKE LINE OF it_resultattrtab . |
The below ABAP code uses the older none in-line data declarations. This allows you to see the coding differences/benefits of the later inline syntax. It may also be useful if you are using an older version of SAP as some of the newer syntax above, such as the @DATA is not available until 4.70 EHP 8.
DATA:
| ld_numofhits | TYPE SRETGSTRUC-NUMOFHIT , |
| ld_catid | TYPE SRETIDCAT-CATID , |
| it_languagetab | TYPE STANDARD TABLE OF SRETLAN2 , |
| wa_languagetab | LIKE LINE OF it_languagetab, |
| ld_rcode | TYPE SRETGSTRUC-RCODE , |
| ld_docuspace | TYPE SDOKDOCSPH-DOCUSPACE , |
| it_queryparamtab | TYPE STANDARD TABLE OF SRETQATR1 , |
| wa_queryparamtab | LIKE LINE OF it_queryparamtab, |
| ld_es_errorcode | TYPE SRETSERRORCODE , |
| it_xmlquerytab | TYPE STANDARD TABLE OF SRETQXSE , |
| wa_xmlquerytab | LIKE LINE OF it_xmlquerytab, |
| it_docattrtab | TYPE STANDARD TABLE OF SRETATR2 , |
| wa_docattrtab | LIKE LINE OF it_docattrtab, |
| it_resultdoctab | TYPE STANDARD TABLE OF SRETRESDOC , |
| wa_resultdoctab | LIKE LINE OF it_resultdoctab, |
| it_resultattrtab | TYPE STANDARD TABLE OF SRETDCATVL , |
| wa_resultattrtab | LIKE LINE OF it_resultattrtab. |
Please help keep this info upto date and use the comments section below to add useful hints, tips and information specific to this SAP function. This will then be available for you and other users to easily find by simply searching on the object name SRET_DOCUMENTS_SEARCH_XML_NEW or its description.