[ABAP] Infos zum Archiv lesen

*           Paket: SAOP
*                  SCMS
* Funktionsgruppe: SCMS_AO_API
* Tabellen: TOAAR: Kommunikationskonfigurationstabelle Ablagesysteme
*           TOADV: SAP ArchiveLink: Globale Dokumentarten SAP ArchiveLink
*           TOAOM: SAP ArchiveLink: Metatabelle für Verknüpfungen
*           TOADD: SAP ArchiveLink Prüftabelle DOK_Typ
*           TOJTB: Business Object Repository Grunddaten
*           TOA01: Verknüpfungstabelle 1
*           TOA02: Verknüpfungstabelle 2
*           TOA03: Verknüpfungstabelle 3
*           TOAAT: Table to store the File attributes
*           TOACO: Prüftabelle für die Verknüpfungstabellen

* Archiv-ID aus Tabelle TOAAR
PARAMETERS: p_arc TYPE toaar-archiv_id.

START-OF-SELECTION.

  DATA: lv_version TYPE char64.
  DATA: lv_protocol TYPE char64.
  DATA: lv_basicpath TYPE char255.
  DATA: lv_archivpath  TYPE char255.
  DATA: lv_spoolpath TYPE char255.
  DATA: lv_phys_basicpath TYPE char255.
  DATA: lv_phys_archivpath TYPE char255.
  DATA: lv_client_dependend TYPE sy-datar.
  DATA: lv_rep_type TYPE scms_crtyp.

* CMS: AO API Archivinformation
  CALL FUNCTION 'SCMS_ARCHIVE_INFO_GET'
    EXPORTING
      arc_id           = p_arc
    IMPORTING
      version          = lv_version
      protocol         = lv_protocol
      basicpath        = lv_basicpath
      archivpath       = lv_archivpath
      spoolpath        = lv_spoolpath
      phys_basicpath   = lv_phys_basicpath
      phys_archivpath  = lv_phys_archivpath
      client_dependend = lv_client_dependend
      rep_type         = lv_rep_type
    EXCEPTIONS
      error_config     = 1
      OTHERS           = 2.

  IF sy-subrc = 0.
    WRITE: / |Version: { lv_version }|.
    WRITE: / |Protokoll { lv_protocol }|.
    WRITE: / |BasicPath: { lv_basicpath }|.
    WRITE: / |ArchivPath: { lv_archivpath }|.
    WRITE: / |SpoolPath: { lv_spoolpath }|.
    WRITE: / |PhysBasicPath: { lv_phys_basicpath }|.
    WRITE: / |PhysArchivPath: { lv_phys_archivpath }|.
    WRITE: / |ClientDependend: { lv_client_dependend }|.
    WRITE: / |RepType: { lv_rep_type }|.
  ENDIF.