SAP OSS Notes

609541 SAP OSS Note - Alte und neue Auftragsverwaltung








SAP OSS Note 609541 version 0001 contains details of a know issue related to Alte und neue Auftragsverwaltung. This includes any associated symptoms and instructions on how to fix it, see below for full details. Also check out the comments section to view/add related contributions, questions or screen shots, based on real life experience of this oss note and problem.

...For more information about the SAP support system known as OSS please check out the SAP OSS NOTES SECTION, whih includes how to download & implement them onto your SAP system using transaction code SNOTE.

Note 609541 Details:






When does this problem occur

Zu Release 6.10 wurde die ArchiveLink-Auftragsverwaltung umgestellt. In TA OAM1 kann zwischen der alten und neuen Auftragsverwaltung umgeschaltet werden. Da sich das Umschalten auch auf bereits erzeugte Aufträge auswirkt, muss unbedingt darauf geachtet werden, dass zum Abarbeiten alter Aufträge die neue Auftragsverwaltung abgeschaltet wird.

Description of problem



Cause of the problem and Pre-requisites

Fehler im Coding

Solution instructions

Die Korrektur sogt dafür, dass die aktuelle Einstellung keinen Einfluss auf bereits existierende Aufträge hat.
Falls Sie die Korrektur mit dem Note Assistant einpflegen, müssen Sie vorab manuell das Programm OAQUEUES anlegen. Zum Anlegen verwenden Sie bitte die TA SE38. Das Programm hat den Typ Formroutinen-Pool und gehört zum Paket SAOD. Außerdem müssen für OAQUEUES folgende Textsymbole gepflegt werden:

Sym Text dLen mLen
063 Soll die HTTP Ablage im Dialog oder im Hintergrund 50 50
064 gestartet werden ? 18 18
065 Dialog 6 6
066 Hintergrund 11 11
067 Aufruf HTTP Ablage 18 18
069 Wollen Sie den Auftrag wirklich löschen ? 41 41
070 Auftrag löschen 15 15
071 Auftrag nicht löschen 21 21
072 Löschen asynchroner Auftrag 27 27
073 Der Auftrag ist noch nicht vollständig abgearbeitet 51 51
099 Fehler bei QUEUE_OPEN 21 21


Note 609541 Correction instructions:



NOTE: Only source text changes are displayed here

*$*$----------------------------------------------------------------$*$*
*$ CORRECTION INSTRUCTIONS 0120061532 0000536981 $*
*$ Prerequisite corr. inst. 0120061532 0000431923 Note 0000535456 $*
*$ 0120061532 0000528307 Note 0000603812 $*
*$--------------------------------------------------------------------$*
*$ VALID FOR : $*
*$ Software Component SAP_BASIS SAP Basis component $*
*$ Release 620 To SAPKB62022 $*
*$*$----------------------------------------------------------------$*$*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINKCARAHTTP
*& Object header PROG ARCHIVELINKCARAHTTP
*&---------------------------------------------------------------------*
*& REPORT ARCHIVELINKCARAHTTP
*&---------------------------------------------------------------------*
...
parameters: request like toacr-unit.

include rsqapidf.
include archivelink_caraconstants.
include archivelink_queuedeclarations.
**
*>>>> START OF DELETION <<<<<
data: g_toacr like toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
data: f_toacr like toacr.
data: g_toacr like toacr.
*>>>> END OF INSERTION <<<<<<
...
data: dummypath like g_toacr-path. clear dummypath.

perform split_path(oaall) using g_toacr-path dummypath filename.
ref_code = g_toacr-unit. ref_code+32(5) = 'TOACR'.
g_toacr-reqstatus = CARAHTTPPROCESSED.
*>>>> START OF DELETION <<<<<
perform get_next_timestamp using g_toacr-lnr.
insert into toacr values g_toacr.
g_toacr-reqstatus = CARACFBCCALLED.
perform get_next_timestamp using g_toacr-lnr.
insert into toacr values f_toacr.
g_toacr-reqstatus = CARAFINISHED.
perform get_next_timestamp using g_toacr-lnr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform get_next_timestamp(OAQUEUES) using g_toacr-lnr.
insert into toacr values g_toacr.
g_toacr-reqstatus = CARACFBCCALLED.
perform get_next_timestamp(OAQUEUES) using g_toacr-lnr.
insert into toacr values f_toacr.
g_toacr-reqstatus = CARAFINISHED.
perform get_next_timestamp(OAQUEUES) using g_toacr-lnr.
*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'SCMS_AO_FILE_CREATE_ASYNC'
EXPORTING
ARC_ID = g_toacr-contrep
FILE = filename
DOC_TYPE = g_toacr-doc_class
refer_code = ref_code
EXCEPTIONS
* ERROR_HTTP = 1
* ERROR_ARCHIV = 2
* ERROR_KERNEL = 3
* ERROR_CONFIG = 4
* ERROR_FILE = 5
OTHERS = 1
.
IF SY-SUBRC <> 0.
g_toacr-reqstatus = ERRORCARAHTTPCALL.
*>>>> START OF DELETION <<<<<
perform trans_messages_cara using g_toacr sy-msgid sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3
sy-msgv4.
perform get_next_timestamp using g_toacr-lnr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform trans_messages_cara(OAQUEUES) using g_toacr sy-msgid sy-msgno
sy-msgv1 sy-msgv2 sy-msgv3
sy-msgv4.
perform get_next_timestamp(OAQUEUES) using g_toacr-lnr.
*>>>> END OF INSERTION <<<<<<
...
endif.
** Callback
*data: cfbc like toa_cfbc. clear cfbc.
*data: g_toaar like toaar. clear g_toaar.
*data: messagestring like sapb-sapmessage. clear messagestring.
** build the CFBC-String
*cfbc-function = 'CFBC'.
*cfbc-sign = g_toacr-unit.
*cfbc-ret_code = space.
*cfbc-mandant = g_toacr-reqclient.
*cfbc-del_date = space.
*cfbc-sap_object = space.
*cfbc-ar_object = space.
*cfbc-object_id = space.
*cfbc-reserve = space.
*cfbc-archiv_id = g_toacr-contrep.
*cfbc-arc_doc_id = cfbc_doc_id.
*cfbc-datalength = space.
*cfbc-desclength = space.
*cfbc-d_arc_d_id = space.
*cfbc+36(5) = 'TOACR'.
*select single * from toaar into g_toaar
* where archiv_id = g_toacr-contrep.
*messagestring(8) = g_toaar-protokoll.
*messagestring+8(4) = g_toaar-version.
*messagestring+12 = cfbc.
*
*CALL FUNCTION 'ARCHIV_SEND'
* EXPORTING
* CALL_MESSAGESTRING = messagestring.

*---------------------------------------------------------------------*
* FORM trans_messages_cara *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
* --> MSGID *
* --> MSGNR *
* --> MSGV1 *
* --> MSGV2 *
* --> MSGV3 *
* --> MSGV4 *
*---------------------------------------------------------------------*
*form trans_messages_cara using f_toacr structure toacr
* msgid msgnr msgv1 msgv2 msgv3 msgv4.
* f_toacr-msgid = msgid.
* f_toacr-msgnr = msgnr.
* f_toacr-msgv1 = msgv1.
* f_toacr-msgv2 = msgv2.
* f_toacr-msgv3 = msgv3.
* f_toacr-msgv4 = msgv4.
*endform.
*>>>> START OF DELETION <<<<<

include archivelink_queues.
*>>>> END OF DELETION <<<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_CARA
*& Object header PROG ARCHIVELINK_CARA
*&---------------------------------------------------------------------*
*& REPORT ARCHIVELINK_CARA
*&---------------------------------------------------------------------*
...
REPORT ARCHIVELINK_CARA message-id oa.

* Definements
include rsqapidf.
include archivelink_caraconstants.
include archivelink_queuedeclarations.


parameters: queue like apqi-qid default CARAQUEUE.

data: f_cara like toa_cara.
*>>>> START OF DELETION <<<<<
perform queue_open using CARAQUEUE Q_READ.
perform queue_get tables t_buffer using caraqueue.
loop at t_buffer.
clear f_cara.
move t_buffer-s_buffer to f_cara.
move t_buffer-unit to unit.
perform process_queue_cara using caraqueue unit f_cara.
endloop.
perform queue_close using caraqueue.

* Forms
include archivelink_queues.





.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform queue_open(OAQUEUES) using CARAQUEUE Q_READ.
perform queue_get(OAQUEUES) tables t_buffer using caraqueue.
loop at t_buffer.
clear f_cara.
move t_buffer-s_buffer to f_cara.
move t_buffer-unit to unit.
perform process_queue_cara(OAQUEUES) using caraqueue unit f_cara.
endloop.
perform queue_close(OAQUEUES) using caraqueue.

* Forms
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_CARACONSTANTS
*& Object header PROG ARCHIVELINK_CARACONSTANTS
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Include ARCHIVELINK_CARACONSTANTS
**&---------------------------------------------------------------------
*
*>>>> START OF DELETION <<<<<
DATA: LTEXT LIKE TSL1T-TXT.
data: cfbcstruct like toa_cfbc.


* kind of queues
data: CARAQUEUE like apqi-qid value 'CARA'.
data: CARAERRORQUEUE like apqi-qid value 'CARA_E'.
data: CFBCQUEUE like apqi-qid value 'CFBC'.

* queuenames
data: CARA(4) value 'CARA'.


* necessary because of archivelink_api
data: RFC like toain-s_methode value 'RFC'.


* kind of requests
data: CARASPOOLREQUEST type alint value 1,
DONTKNOW type alint value 10.
* Debugging
data: check(1) value 'X',
nocheck(1) value '1'.

* CARA-Requeststatus

data: REQUESTCREATED type alint value 1000,
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<

constants:
* kind of queues
caraqueue like apqi-qid value 'CARA',
caraerrorqueue like apqi-qid value 'CARA_E',
cfbcqueue like apqi-qid value 'CFBC',

* queuenames
cara(4) value 'CARA',


* necessary because of archivelink_api
rfc like toain-s_methode value 'RFC',


* kind of requests
caraspoolrequest type alint value 1,
dontknow type alint value 10,
* Debugging
check(1) value 'X',
nocheck(1) value '1',

* CARA-Requeststatus

requestcreated type alint value 1000,
*>>>> END OF INSERTION <<<<<<
...
SPOOLINFOSFOUND type alint value 1001,
RFCCARASENTTOCONTREP type alint value 1002,
CARAJOBSTARTED type alint value 1003,
CARAHTTPPROCESSED type alint value 1004,
CARACFBCCALLED type alint value 1005,
*>>>> START OF DELETION <<<<<
CARAFINISHED type alint value 10000.

* CARA-Errorrequeststatus must be smaller than REQUESTCREATED
data: NOSPOOLINFOS type alint value 1,
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
carafinished type alint value 10000,

* CARA-Errorrequeststatus must be smaller than REQUESTCREATED
nospoolinfos type alint value 1,
*>>>> END OF INSERTION <<<<<<
...
ERRORINRFCCARASENTTOCONTREP type alint value 2,
ERRORSTARTINGCARAJOB type alint value 3,
ERRORCARAHTTPCALL type alint value 4,
CARALOGDELETIONERROR type alint value 5,
USERCANCELED type alint value 901,
*>>>> START OF DELETION <<<<<
UNDEFINEDCARAERROR type alint value 999.


* CFBC-Requeststatus
data: CFBCNEWCREATED type alint value 100000,
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
undefinedcaraerror type alint value 999,


* CFBC-Requeststatus
cfbcnewcreated type alint value 100000,
*>>>> END OF INSERTION <<<<<<
...
CFBCARCHIVOKAY type alint value 100002,
CFBCSPOOLINFORMEDAO type alint value 100003, "First door out
CFBCTOADLOKAY type alint value 100004,
CFBCDVSOKAY type alint value 100005,
CFBCDVSNOTNEEDED type alint value 100006,
CFBCSPOOLINFORMEDOK type alint value 100007,
*>>>> START OF DELETION <<<<<
CFBCFINISHED type alint value 1000000.


* CFBC-Errorrequeststatus must be smaller than CFBCNEWCREATED
data: CFBCNOCARAFOUND type alint value 10001,
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
cfbcfinished type alint value 1000000,


* CFBC-Errorrequeststatus must be smaller than CFBCNEWCREATED
cfbcnocarafound type alint value 10001,
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_CFBC
*& Object header PROG ARCHIVELINK_CFBC
*&---------------------------------------------------------------------*
*& REPORT ARCHIVELINK_CFBC
*&---------------------------------------------------------------------*
...
include archivelink_queuedeclarations.
***
data: cfbc like toa_cfbc.
clear cfbc.
data: h_unit like toacr-unit. clear h_unit.
data: g_toacr like toacr. clear g_toacr.
*>>>> START OF DELETION <<<<<
clear f_toars.
***
* Write it to log
clear f_toacb.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
data: f_toacb like toacb.
data: f_toacb_head like toacb_head.
***
* Write it to log
*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'GUID_CREATE'
IMPORTING
EV_GUID_32 = f_toacb-unit.
f_toacb-reqkind = DONTKNOW.
endif.
f_toacb-reqstatus = CFBCNEWCREATED.
f_toacb-message = message(255).
*>>>> START OF DELETION <<<<<
perform get_next_timestamp using f_toacb-lnr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform get_next_timestamp(OAQUEUES) using f_toacb-lnr.
*>>>> END OF INSERTION <<<<<<
...
insert into toacb_head values f_toacb_head.
commit work.
* Protocol that no cara is found
if f_toacb-reqkind = DONTKNOW.
f_toacb-reqstatus = CFBCNOCARAFOUND.
*>>>> START OF DELETION <<<<<
perform get_next_timestamp using f_toacb-lnr.
insert into toacb values f_toacb.
exit.
else.
* Check archiverror
perform check_archiverror using f_toacb. "Exit, if error
* if g_toacr-reqstatus = CARAFINISHED.
perform process_cfbc using cfbcqueue f_toacb g_toacr check.
* endif.
endif.



include archivelink_queues.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform get_next_timestamp(OAQUEUES) using f_toacb-lnr.
insert into toacb values f_toacb.
exit.
else.
* Check archiverror
perform check_archiverror(OAQUEUES) using f_toacb.
"Exit, if error
* if g_toacr-reqstatus = CARAFINISHED.
perform process_cfbc(OAQUEUES) using cfbcqueue f_toacb g_toacr check.
* endif.
endif.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_MONITOR_ASYNC
*& Object header PROG ARCHIVELINK_MONITOR_ASYNC
*&---------------------------------------------------------------------*
*& REPORT ARCHIVELINK_MONITOR_ASYNC
*&---------------------------------------------------------------------*
...
include archivelink_queuedeclarations.
include .
TYPE-POOLS: SLIS.

*
*>>>> START OF DELETION <<<<<
clear f_toars. clear f_toacr. clear f_toacb.
clear f_toacr_head.
clear f_toacb_head.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
data: f_toacr like toacr.
data: f_toacr_head like toacr_head.
data: f_toacb like toacb.
data: f_toacb_head like toacb_head.



*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& AT USER-COMMAND
*&---------------------------------------------------------------------*
...
if f_toacr-reqstatus = CARAFINISHED
or f_toacr-reqstatus = CARAHTTPPROCESSED
or f_toacr-reqstatus = CARACFBCCALLED.
message I276.
else.
*>>>> START OF DELETION <<<<<
perform process_next_cara using f_toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform process_next_cara(OAQUEUES) using f_toacr.
*>>>> END OF INSERTION <<<<<<
...
if f_toacr-reqstatus = CARAFINISHED
or f_toacr-reqstatus = CARAHTTPPROCESSED
or f_toacr-reqstatus = CARACFBCCALLED.
message I276.
else.
*>>>> START OF DELETION <<<<<
perform process_cara using caraqueue f_toacr nocheck.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform process_cara(OAQUEUES) using caraqueue f_toacr nocheck.
*>>>> END OF INSERTION <<<<<<
...
submit: ARCHIVELINK_MONITOR_ASYNC with kind = 'CFBC'
with sunit = f_toacb_head-unit.
endif.
* i want to see the job(s)
when 'CARAJOB'.
read table i_toacr index 1.
*>>>> START OF DELETION <<<<<
perform display_job using i_toacr.
* Delete the request
when 'DELECARA'.
read table i_toacr index 1.
perform delete_single_cara tables i_toacr using i_toacr-unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform display_job(OAQUEUES) using i_toacr.
* Delete the request
when 'DELECARA'.
read table i_toacr index 1.
perform delete_single_cara(OAQUEUES) tables i_toacr using
i_toacr-unit.
*>>>> END OF INSERTION <<<<<<
...
if f_toacb-reqstatus = CFBCFINISHED.
message I276.
elseif f_toacb-reqstatus = CFBCNOCARAFOUND.
message I277.
else.
*>>>> START OF DELETION <<<<<
perform process_next_cfbc using f_toacb f_toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform process_next_cfbc(OAQUEUES) using f_toacb f_toacr.
*>>>> END OF INSERTION <<<<<<
...
elseif f_toacb-reqstatus = CFBCNOCARAFOUND.
message I277.
else.
select * from toacr into f_toacr where unit = f_toacb-unit.
endselect.
*>>>> START OF DELETION <<<<<
perform process_cfbc using cfbcqueue f_toacb f_toacr nocheck.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform process_cfbc(OAQUEUES) using cfbcqueue f_toacb f_toacr
nocheck.
*>>>> END OF INSERTION <<<<<<
...
submit: ARCHIVELINK_MONITOR_ASYNC with kind = 'CARA'
with sunit = f_toacr_head-unit.
endif.
* Deleterequest
when 'DELESINGLE'.
read table i_toacb index 1.
*>>>> START OF DELETION <<<<<
perform delete_single_entry using i_toacb-unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform delete_single_entry(OAQUEUES) using i_toacb-unit.
*>>>> END OF INSERTION <<<<<<
...
when others.
endcase.




*>>>> START OF DELETION <<<<<
include archivelink_queues.
*>>>> END OF DELETION <<<<<<<
...
*&---------------------------------------------------------------------*
*& FORM USER_COMMAND
*&---------------------------------------------------------------------*
...
form user_command using ucomm like sy-ucomm selfield type slis_selfield.
data: smallunit like toacb-unit. clear smallunit.
case sy-ucomm.
* Löschen alle erledigten Aufträge
when 'DELE'.
*>>>> START OF DELETION <<<<<
perform delete_all_finished.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform delete_all_finished(OAQUEUES).
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_QUEUEDECLARATIONS
*& Object header PROG ARCHIVELINK_QUEUEDECLARATIONS
*&---------------------------------------------------------------------*
...
DATA: BEGIN OF I_BUFFER OCCURS 1,
UNIT LIKE APQD-TRANS,
BUFFER(1000),
END OF I_BUFFER.
data: APQD_BUFFER LIKE APQD-VARDATA.
*>>>> START OF DELETION <<<<<

* Requesttable for CARA
data: f_toacr like toacr.
data: f_toacr_head like toacr_head.

DATA: STATE LIKE APQI-QSTATE VALUE 'S',
LENGTH LIKE APQD-TRANS.


* Answertable for CFBC
data: f_toacb like toacb.
data: f_toacb_head like toacb_head.
* Customizingtable
data: f_toars like toars.
*>>>> END OF DELETION <<<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ARCHIVELINK_QUEUES
*& Object header PROG ARCHIVELINK_QUEUES
*&---------------------------------------------------------------------*
*& FORM QUEUE_OPEN
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
*INCLUDE RSQAPIDF. " QAPI Defines


*DATA: LTEXT LIKE TSL1T-TXT.
*data: cfbcstruct like toa_cfbc.
*
*&---------------------------------------------------------------------*
*& Include ARCHIVELINK_QUEUES *
*&---------------------------------------------------------------------*

FORM QUEUE_OPEN USING QUEUE MODE LIKE APQI-QSTATE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
*&---------------------------------------------------------------------*
*& Include ARCHIVELINK_QUEUES *
*&---------------------------------------------------------------------*


*&---------------------------------------------------------------------*
*& Form queue_open
*&---------------------------------------------------------------------*
form queue_open using queue mode like apqi-qstate.
data:
ltext like tsl1t-txt.

*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'QUEUE_OPEN'
EXPORTING
NAME = QUEUE " Queue ID
OPENMODE = MODE
EXCEPTIONS
INVALID_NAME = 1
INVALID_PARAMETER = 2
INVALID_USERID_PWD = 3
NOT_FOUND = 4
OPEN_ERROR = 5
QUEUE_IN_PROCESS = 6
Q_ERROR = 7
SQL_ERROR = 8
FOREIGN_LOCK = 9
SYSTEM_FAILURE = 10
OTHERS = 11.
IF SY-SUBRC NE 0.
* write SYSLOG
*>>>> START OF DELETION <<<<<
LTEXT = 'Fehler QUEUE_OPEN'(099).
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
ltext = 'Fehler bei QUEUE_OPEN'(099).
*>>>> END OF INSERTION <<<<<<
...
PERFORM WRITE_ALERT(OAALERT) USING SY-MSGNO 2.
MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
ENDFORM.
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_CLOSE
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form queue_close
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_CARAQUEUE text
*----------------------------------------------------------------------*
FORM queue_close USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form queue_close using queue.
*>>>> END OF INSERTION <<<<<<
...
IF SY-SUBRC NE 0.
MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
COMMIT WORK.
*>>>> START OF DELETION <<<<<


ENDFORM. " queue_close
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform. " queue_close

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_GET
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form queue_get
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_T_BUFFER text
* -->P_CARAQUEUE text
*----------------------------------------------------------------------*
FORM queue_get TABLES T_BUFFER STRUCTURE I_BUFFER
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form queue_get tables t_buffer structure i_buffer
*>>>> END OF INSERTION <<<<<<
...
ENDIF.
MOVE UNIT TO T_BUFFER-UNIT.
MOVE APQD_BUFFER TO T_BUFFER-BUFFER.
APPEND T_BUFFER.
ENDDO.
*>>>> START OF DELETION <<<<<

ENDFORM. "queue_get

*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform. "queue_get
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_QUEUE_CARA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM process_queue_cara *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> UNIT *
* --> CARAQUEUE *
*---------------------------------------------------------------------*
FORM process_queue_cara using CARAQUEUE unit f_cara.
clear f_toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_queue_cara using caraqueue unit f_cara.
*>>>> END OF INSERTION <<<<<<
...
data: answer like sy-subrc. clear answer.
perform process_queue_cara_wo using caraqueue unit f_cara answer.
if answer = 0.
perform queue_delete using caraqueue unit.
else.
*>>>> START OF DELETION <<<<<
* if answer <> 0.
perform queue_transfer using CARAERRORQUEUE f_cara.
perform queue_delete using CARAQUEUE unit. .
endif.
* endif.

****
***
**
ENDFORM. " process_queue_cara
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform queue_transfer using caraerrorqueue f_cara.
perform queue_delete using caraqueue unit.
endif.
endform. " process_queue_cara

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_QUEUE_CARA_WO
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM process_queue_cara_wo *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> CARAQUEUE *
* --> UNIT *
* --> F_CARA *
* --> ANSWER *
*---------------------------------------------------------------------*
form process_queue_cara_wo using CARAQUEUE unit f_cara answer.

**
data: debugon. clear debugon.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_queue_cara_wo using caraqueue unit f_cara answer.

**
data: debugon. clear debugon.
data: f_toacr like toacr.
data: f_toacr_head like toacr_head.
*>>>> END OF INSERTION <<<<<<
...
data: debugcheck(1).
debugcheck = check.
if debugon <> 'X'.
perform process_cara using caraqueue f_toacr debugcheck.
endif.
*>>>> START OF DELETION <<<<<


endform.

*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CARA_TO_TOACR
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM cara_to_toacr *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_CARA *
* --> F_TOACR *
*---------------------------------------------------------------------*
form cara_to_toacr using f_cara structure toa_cara
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form cara_to_toacr using f_cara structure toa_cara
*>>>> END OF INSERTION <<<<<<
...
f_toacr-sdate = f_cara-datum.
f_toacr-suser = f_cara-benutzer.
f_toacr-printer = f_cara-drucker.
f_toacr-form = f_cara-formular.
f_toacr-path = f_cara-s_path.
*>>>> START OF DELETION <<<<<






endform.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_TRANSFER
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM QUEUE_TRANSFER *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> QUEUE *
* --> BUFFER *
*---------------------------------------------------------------------*
FORM QUEUE_TRANSFER USING QUEUE BUFFER.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form queue_transfer using queue buffer.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_PUT
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM QUEUE_PUT *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> QUEUE *
* --> BUFFER *
*---------------------------------------------------------------------*
FORM QUEUE_PUT USING QUEUE BUFFER.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form queue_put using queue buffer.
data:
state like apqi-qstate,
length like apqd-trans.

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_DELETE
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM QUEUE_DELETE *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> QUEUE *
* --> UNIT *
*---------------------------------------------------------------------*
FORM QUEUE_DELETE USING QUEUE UNIT.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form queue_delete using queue unit.
*>>>> END OF INSERTION <<<<<<
...
MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
COMMIT WORK.
ENDFORM.
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM ADD_TIMESTAMP
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form add_timestamp
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACR_REQ_DATE text
* -->P_REQ_TIME text
*----------------------------------------------------------------------*
FORM add_timestamp USING REQ_DATE
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form add_timestamp using req_date
*>>>> END OF INSERTION <<<<<<
...
data: timestamp like tzonref-tstamps.

get time stamp field timestamp.
convert time stamp timestamp time zone ' '
into date req_date time req_time.
ENDFORM. " add_timestamp
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM GET_NEXT_TIMESTAMP
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form get_next_timestamp
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACR_LNR text
*----------------------------------------------------------------------*
FORM get_next_timestamp USING LNR.
data: l_tst TYPE timestampl. clear l_tst.
get time.
get time stamp field l_tst.
lnr = l_tst.



ENDFORM. " get_next_timestamp
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form get_next_timestamp using lnr.
data: l_tst TYPE timestampl. clear l_tst.
get time.
get time stamp field l_tst.
lnr = l_tst.
endform. " get_next_timestamp

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CHECK_DEBUGMODE
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form check_debugmode
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_CARAQUEUE text
*----------------------------------------------------------------------*
FORM check_debugmode USING queue debugon.
clear f_toars.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form check_debugmode using queue debugon.
data: f_toars like toars.

*>>>> END OF INSERTION <<<<<<
...
debugon = 'X'.
endif.
when others.
endcase.
endif.
*>>>> START OF DELETION <<<<<


ENDFORM. " check_debugmode
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform. " check_debugmode

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_CARA
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form process_it
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_CARAQUEUE text
* -->P_F_TOACR text
*----------------------------------------------------------------------*
FORM process_cara USING CARAQUEUE
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_cara using caraqueue
*>>>> END OF INSERTION <<<<<<
...
if debugon = 'X'.
exit.
endif.
endif.
enddo.
*>>>> START OF DELETION <<<<<

ENDFORM.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform.

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_CFBC
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM process_cfbc *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> CFBCQUEUE *
* --> F_TOACB *
*---------------------------------------------------------------------*
FORM process_cfbc using CFBCQUEUE
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_cfbc using cfbcqueue
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_NEXT_CARA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM process_next_step *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form process_next_cara using f_toacr structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_next_cara using f_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
f_toacr-reqstatus = CARAFINISHED.
* nothing to do: HTTP deletes
* when CARAHTTPPROCESSED.
* perform delete_cara_log using f_toacr.
* something must have been wrong
when others.
f_toacr-reqstatus = UNDEFINEDCARAERROR.
endcase.
*>>>> START OF DELETION <<<<<




endform.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform.

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_NEXT_CFBC
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM process_next_cfbc *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACB *
* --> G_TAOCR *
*---------------------------------------------------------------------*
form process_next_cfbc using f_toacb structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form process_next_cfbc using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
f_toacb-reqstatus = UNDEFINEDCFBCERROR.
perform get_next_timestamp using f_toacb-lnr.
insert into toacb values f_toacb.
commit work.
endcase.
*>>>> START OF DELETION <<<<<



endform.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CHECK_SPOOL
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM check_spool *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form check_spool using f_toacr structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form check_spool using f_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CREATE_CARA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM create_cara *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form create_cara using f_toacr structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form create_cara using f_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CREATE_CARA_RFC
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM create_cara_rfc *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form create_cara_rfc using f_toacr structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form create_cara_rfc using f_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
data: ref_code(40). clear ref_code.
*
perform clear_messages using f_toacr.
perform split_path(oaall) using f_toacr-path pathnotneeded filename.
ref_code = f_toacr-unit. ref_code+32(5) = 'TOACR'.
*>>>> START OF DELETION <<<<<
***** old way

* i_api_values-t_arch_id = f_toacr-contrep.
* i_api_values-doc_type = f_toacr-doc_class.
* i_api_values-client = f_toacr-reqclient.
* clear i_api_values-expir_date.
* i_api_values-s_path = filename.
* i_api_values-refer_code = f_toacr-spoolid.
* i_api_values-refer_code = f_toacr-unit.
* i_api_values-refer_code+20 = 'TOACR'.
* i_api_values-func_name = CARA.
* aid = i_api_values-t_arch_id.
* CALL FUNCTION 'ARCHIVELINK_API'
* EXPORTING
* ARCHIV_ID = aid
* FUNC_NAME = i_api_values-func_name
* API_VALUES = i_api_values
* COMMUNICATIONTYPE = RFC
* EXCEPTIONS
* OTHERS = 0.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
f_toacr-reqstatus = CARAFINISHED.
insert into toacr values f_toacr.
commit work.
endif.
endform.
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CREATE_CARA_HTTP
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM create_cara_http *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form create_cara_http using f_toacr structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form create_cara_http using f_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'JOB_OPEN'
EXPORTING
JOBNAME = jobname
IMPORTING
JOBCOUNT = jobnumber
EXCEPTIONS
*>>>> START OF DELETION <<<<<
OTHERS = 0.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
others = 1.
*>>>> END OF INSERTION <<<<<<
...
endif.
perform get_next_timestamp using f_toacr-lnr.
insert toacr from f_toacr.
commit work.
endform.
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CHECK_ARCHIVERROR
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form check_archiverror
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_G_TOACB text
*----------------------------------------------------------------------*
fORM check_archiverror USING f_toacb structure toacb.
**
clear cfbcstruct.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form check_archiverror using f_toacb structure toacb.
**
data: cfbcstruct like toa_cfbc.
*>>>> END OF INSERTION <<<<<<
...
call function 'ARCHIV_UPDATE_STATUS'
EXPORTING
errorkey = 'OA623'
spoolid = cfbcstruct-sign
status = '2'
EXCEPTIONS
others = 0.
*>>>> START OF DELETION <<<<<
.
IF SY-SUBRC <> 0.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
if sy-subrc <> 0.
*>>>> END OF INSERTION <<<<<<
...
insert into toacb values f_toacb.
commit work.
leave program.
endif.
ENDFORM. " check_archiverror
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM INSERT_INTO_TOADL
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form insert_into_toadl
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACB text
* -->P_G_TOACR text
* -->P_A_CFBC text
*----------------------------------------------------------------------*
FORM insert_into_toadl USING F_TOACB structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form insert_into_toadl using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
endif.
int_toadl-datalength = a_cfbc-desclength.
if a_cfbc-desclength cn ' 0123456789'.
a_cfbc-desclength = space.
endif.
*>>>> START OF DELETION <<<<<
int_toadl-desclength = a_cfbc-desclength..
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
int_toadl-desclength = a_cfbc-desclength.
*>>>> END OF INSERTION <<<<<<
...
commit work.
* Insert Kpro
* call function 'ALINK_KPRO_ENTRY_CREATE'
* EXPORTING
* CLIENT = int_toadl-mandant
* PRINTLIST_ENTRY = int_toadl
* X_PRINTLIST = 'X'
* EXCEPTIONS
* LOIO_PHIO_NOT_CREATED = 1
* OTHERS = 2.
* if sy-subrc <> 0.
** No error handling. Silent exit
* endif.

ENDFORM. " insert_into_toadl
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM INSERT_INTO_DVS
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form insert_into_dvs
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACB text
* -->P_G_TOACR text
* -->P_A_CFBC text
*----------------------------------------------------------------------*
FORM insert_into_dvs USING F_TOACB structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form insert_into_dvs using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TRANSFORM_TO_DVS_IF
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM transform_to_dvs_if *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACB *
* --> G_TOACR *
* --> A_CFBC *
* --> DVS_SPOOLSTRUCT *
*---------------------------------------------------------------------*
form transform_to_dvs_if using F_TOACB structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form transform_to_dvs_if using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TRANS_MESSAGES_CFBC
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM trans_messages_cfbc *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACB *
* --> MSGID *
* --> MSGNR *
* --> MSGV1 *
* --> MSGV2 *
* --> MSGV3 *
* --> MSGV4 *
*---------------------------------------------------------------------*
form trans_messages_cfbc using f_toacb structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form trans_messages_cfbc using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
f_toacb-msgv1 = msgv1.
f_toacb-msgv2 = msgv2.
f_toacb-msgv3 = msgv3.
f_toacb-msgv4 = msgv4.
endform.
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TRANS_MESSAGES_CARA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM trans_messages_cara *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
* --> MSGID *
* --> MSGNR *
* --> MSGV1 *
* --> MSGV2 *
* --> MSGV3 *
* --> MSGV4 *
*---------------------------------------------------------------------*
form trans_messages_cara using f_toacr structure toacr
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form trans_messages_cara using f_toacr structure toacr
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM INFORM_SPOOL_OK
*&---------------------------------------------------------------------*
...
call function 'ARCHIV_UPDATE_STATUS'
EXPORTING
errorkey = ' '
spoolid = wa_toacr-spoolid
status = '0'
EXCEPTIONS
others = 0.
*>>>> START OF DELETION <<<<<
.
IF SY-SUBRC <> 0.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
if sy-subrc <> 0.
*>>>> END OF INSERTION <<<<<<
...
ENDIF.
perform get_next_timestamp using f_toacb-lnr.
insert into toacb values f_toacb.
commit work.
ENDFORM. " inform_spool
*>>>> START OF INSERTION <<<<

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM INFORM_SPOOL_NOK
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM inform_spool_nok *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACB *
* --> A_CFBC *
*---------------------------------------------------------------------*
form inform_spool_nok using f_toacb structure toacb
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form inform_spool_nok using f_toacb structure toacb
*>>>> END OF INSERTION <<<<<<
...
call function 'ARCHIV_UPDATE_STATUS'
EXPORTING
errorkey = 'OA623'
spoolid = wa_toacr-spoolid
status = '2'
EXCEPTIONS
others = 0.
*>>>> START OF DELETION <<<<<
.
IF SY-SUBRC <> 0.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
if sy-subrc <> 0.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_LOG
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form delete_log
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACB text
* -->P_G_TOACR text
*----------------------------------------------------------------------*
FORM delete_log USING F_TOACB structure toacb
G_TOACR structure toacr.

perform clear_cfbc_messages using f_toacb.
clear f_toars.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_log using f_toacb structure toacb
g_toacr structure toacr.
data: f_toars like toars.

perform clear_cfbc_messages using f_toacb.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_CARA_LOG
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM delete_cara_log *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> F_TOACR *
*---------------------------------------------------------------------*
form delete_cara_log using f_toacr structure toacr.
clear f_toars.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_cara_log using f_toacr structure toacr.
data: f_toars like toars.
*>>>> END OF INSERTION <<<<<<
...
select * from toars into f_toars. endselect.
* Nothing found or flag not set
if sy-subrc <> 0 or f_toars-nodeletion <> 'X'.
delete from toacr where unit = f_toacr-unit.
delete from toacr_head where unit = f_toacr-unit.
*>>>> START OF DELETION <<<<<
* if sy-subrc <> 0.
* f_toacr-reqstatus = CARALOGDELETIONERROR.
* perform get_next_timestamp using f_toacr-lnr.
* insert into toacr values f_toacr.
* commit work.
* else.
* f_toacr-reqstatus = CARAFINISHED.
* endif.
* No logdeletion wanted
else.
endif.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endif.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_SINGLE_ENTRY
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM delete_single_entry *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> UNIT *
*---------------------------------------------------------------------*
form delete_single_entry using unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_single_entry using unit.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_SINGLE_CARA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM delete_single_cara *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> UNIT *
*---------------------------------------------------------------------*
form delete_single_cara tables i_toacr structure toacr using unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_single_cara tables i_toacr structure toacr using unit.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_ALL_FINISHED
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM delete_all_finished *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
form delete_all_finished.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_all_finished.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DELETE_ONE_UNIT
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM delete_one_unit *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> UNIT *
*---------------------------------------------------------------------*
form delete_one_unit using unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form delete_one_unit using unit.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DECIDE_IF_BATCH
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form decide_if_batch
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_ANSWER text
*----------------------------------------------------------------------*
FORM decide_if_batch USING ANSWER.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form decide_if_batch using answer.
*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'POPUP_TO_DECIDE'
EXPORTING
* DEFAULTOPTION = '1'
TEXTLINE1 = text-063
TEXTLINE2 = text-064
* TEXTLINE3 = ' '
TEXT_OPTION1 = text-065
TEXT_OPTION2 = text-066
ICON_TEXT_OPTION1 = 'ICON_EXECUTE_OBJECT'
ICON_TEXT_OPTION2 = 'ICON_BACKGROUND_JOB'
TITEL = text-067
* START_COLUMN = 25
* START_ROW = 6
* CANCEL_DISPLAY = 'X'
IMPORTING
ANSWER = answer.
*>>>> START OF DELETION <<<<<
.



ENDFORM. " decide_if_batch
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform. " decide_if_batch
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM ASK_IF_DELETION_UNCOMPLETE
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM ask_if_deletion_uncomplete *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
* --> ANSWER *
*---------------------------------------------------------------------*
form ask_if_deletion_uncomplete using answer.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form ask_if_deletion_uncomplete using answer.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM DISPLAY_JOB
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form display_job
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_I_TOACR text
*----------------------------------------------------------------------*
FORM display_job USING I_TOACR structure toacr.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form display_job using i_toacr structure toacr.
*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'BP_JOB_MANAGEMENT'
EXPORTING
JOBSELECT_DIALOG = dialog
JOBLIST_OPCODE = okcode
JOBSEL_PARAM_INPUT = input
TABLES
*>>>> START OF DELETION <<<<<
JOBLIST = jliste.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
joblist = jliste
*>>>> END OF INSERTION <<<<<<
...
* EXCEPTIONS
* UNKNOWN_SELECTION_ERROR = 1
* INVALID_OPCODE = 2
* INVALID_DIALOG_TYPE = 3
* REFRESH_LIST_REQUIRED = 4
* EMPTY_LIST = 5
* OTHERS = 6
.
IF SY-SUBRC <> 0.
* MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
ENDIF.
*>>>> START OF DELETION <<<<<





ENDFORM. " display_job
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endform. " display_job

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CLEAR_MESSAGES
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form clear_messages
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACR text
*----------------------------------------------------------------------*
FORM clear_messages USING F_TOACR structure toacr.
clear f_toacr-msgid. clear f_toacr-msgnr. clear f_toacr-msgv1.
clear f_toacr-msgv2. clear f_toacr-msgv3. clear f_toacr-msgv4.
ENDFORM. " clear_messages
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form clear_messages using f_toacr structure toacr.
clear f_toacr-msgid. clear f_toacr-msgnr. clear f_toacr-msgv1.
clear f_toacr-msgv2. clear f_toacr-msgv3. clear f_toacr-msgv4.
ENDFORM. " clear_messages

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM CLEAR_CFBC_MESSAGES
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form clear_cfbc_messages
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_F_TOACB text
*----------------------------------------------------------------------*
FORM clear_cfbc_messages USING F_TOACB structure toacb.
clear f_toacb-msgid. clear f_toacb-msgnr. clear f_toacb-msgv1.
clear f_toacb-msgv2. clear f_toacb-msgv3. clear f_toacb-msgv4.
ENDFORM. " clear_cfbc_messages
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
form clear_cfbc_messages using f_toacb structure toacb.
clear f_toacb-msgid. clear f_toacb-msgnr. clear f_toacb-msgv1.
clear f_toacb-msgv2. clear f_toacb-msgv3. clear f_toacb-msgv4.
ENDFORM. " clear_cfbc_messages


*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM GET_TOARS
*&---------------------------------------------------------------------*
*>>>> START OF INSERTION <<<<
*&---------------------------------------------------------------------*
*& Form get_toars
*&---------------------------------------------------------------------*
form get_toars changing f_toars like toars.
select * from toars into f_toars. endselect.
if sy-subrc <> 0.
clear f_toars. "no entry found - set default
endif.
endform.

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM SET_TOARS
*&---------------------------------------------------------------------*
*>>>> START OF INSERTION <<<<
*&---------------------------------------------------------------------*
*& Form set_toars
*&---------------------------------------------------------------------*
form set_toars using f_toars like toars.
delete from toars.
insert into toars values f_toars.
endform.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI01
*& Object header PROG ILQAPI01
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
INCLUDE RSQAPIDF. " QAPI Defines

*>>>> END OF DELETION <<<<<<<
...
*&---------------------------------------------------------------------*
*& FORM QUEUE_GET_UNIT
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* contains
* FORM QUEUE_OPEN USING QUEUE MODE LIKE APQI-QSTATE
* FORM QUEUE_PUT USING QUEUE BUFFER
* FORM QUEUE_GET TABLES T_BUFFER STRUCTURE I_BUFFER USING QUEUE
* FORM QUEUE_CLOSE USING QUEUE
* FORM QUEUE_DELETE USING QUEUE UNIT
* FORM PROCESS_UNIT USING QUEUE UNIT BUFFER
* FORM QUEUE_TRANSFER


* DATA:
* STATE LIKE APQI-QSTATE VALUE 'S',
* LENGTH LIKE APQD-TRANS.
* LTEXT LIKE TSL1T-TXT.

*DATA: BEGIN OF I_BUFFER OCCURS 1,
* UNIT LIKE APQD-TRANS,
* BUFFER(1000),
* END OF I_BUFFER,
* APQD_BUFFER LIKE APQD-VARDATA.
**---------------------------------------------------------------------*
** FORM QUEUE_OPEN *
**---------------------------------------------------------------------*
** ........ *
**---------------------------------------------------------------------*
** --> QUEUE *
**---------------------------------------------------------------------*
*FORM QUEUE_OPEN USING QUEUE MODE LIKE APQI-QSTATE.
* CALL FUNCTION 'QUEUE_OPEN'
* EXPORTING
* NAME = QUEUE " Queue ID
* OPENMODE = MODE
* EXCEPTIONS
* INVALID_NAME = 1
* INVALID_PARAMETER = 2
* INVALID_USERID_PWD = 3
* NOT_FOUND = 4
* OPEN_ERROR = 5
* QUEUE_IN_PROCESS = 6
* Q_ERROR = 7
* SQL_ERROR = 8
* FOREIGN_LOCK = 9
* SYSTEM_FAILURE = 10
* OTHERS = 11.
* IF SY-SUBRC NE 0.
** write SYSLOG
* LTEXT = 'Fehler QUEUE_OPEN'(099).
* CALL FUNCTION 'ARCHIV_WRITE_SYSLOG'
* EXPORTING
* TEXT = LTEXT.
** write ALERT
* PERFORM WRITE_ALERT(OAALERT) USING SY-MSGNO 2.
* MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
* ENDIF.
*ENDFORM.

**---------------------------------------------------------------------*
** FORM QUEUE_PUT *
**---------------------------------------------------------------------*
** ........ *
**---------------------------------------------------------------------*
** --> QUEUE *
** --> BUFFER *
**---------------------------------------------------------------------*
*FORM QUEUE_PUT USING QUEUE BUFFER.
* STATE = Q_SINGLE.
* LENGTH = STRLEN( BUFFER ).
* MOVE BUFFER TO APQD_BUFFER.
* CALL FUNCTION 'QUEUE_PUT'
* EXPORTING
* BUFFER = APQD_BUFFER
* LENGTH = LENGTH
* NAME = QUEUE
* STATE = STATE
** IMPORTING
** POS =
** SQLRC =
** UNIT =
* EXCEPTIONS
* BUFFER_ERROR = 1
* INVALID_PARAMETER = 2
* MEMORY_ERROR = 3
* Q_ERROR = 4
* SQL_ERROR = 5
* OTHERS = 6.
* COMMIT WORK.
* IF SY-SUBRC NE 0.
* MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
* ENDIF.
*ENDFORM.

**---------------------------------------------------------------------*
** FORM QUEUE_GET
***---------------------------------------------------------------------
*
** ........
***---------------------------------------------------------------------
*
** --> T_BUFFER
*** --> QUEUE
*
**---------------------------------------------------------------------*
*FORM QUEUE_GET TABLES T_BUFFER STRUCTURE I_BUFFER USING QUEUE.
* DATA: UNIT LIKE APQD-TRANS, "Nr of Data Unit (Transaction Unit)
* POS LIKE APQD-BLOCK. "Nr of Data Block (Message)
* CLEAR T_BUFFER. REFRESH T_BUFFER.
* UNIT = 1.
* POS = 0.
* DO.
* CALL FUNCTION 'QUEUE_GET'
* EXPORTING
* NAME = QUEUE
** OPENMODE = ' '
* POS = POS
* UNIT = UNIT
* IMPORTING
* BUFFER = APQD_BUFFER
** LENGTH =
* POS = POS
** SQLRC =
** STATE =
* UNIT = UNIT
* EXCEPTIONS
* BUFFER_ERROR = 1
* EOQ = 2
* INVALID_PARAMETER = 3
* MEMORY_ERROR = 4
* Q_ERROR = 5
* SQL_ERROR = 6
* OTHERS = 7.
* IF SY-SUBRC NE 0.
* EXIT.
* ENDIF.
* MOVE UNIT TO T_BUFFER-UNIT.
* MOVE APQD_BUFFER TO T_BUFFER-BUFFER.
* APPEND T_BUFFER.
* ENDDO.
*ENDFORM.

*---------------------------------------------------------------------*
* FORM QUEUE_GET_UNIT *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
* --> T_BUFFER *
* --> QUEUE *
* --> UNIT *
*---------------------------------------------------------------------*
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
*---------------------------------------------------------------------*
* FORM QUEUE_GET_UNIT *
*---------------------------------------------------------------------*
*>>>> END OF INSERTION <<<<<<
...
IF SY-SUBRC NE 0 OR ( INT_UNIT NE UNIT ).
MESSAGE E068(OA) WITH QUEUE UNIT.
ENDIF.
MOVE APQD_BUFFER TO BUFFER.
ENDFORM.
*>>>> START OF DELETION <<<<<

*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<


*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM PROCESS_UNIT
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
**---------------------------------------------------------------------*
** FORM QUEUE_CLOSE *
**---------------------------------------------------------------------*
** ........ *
**---------------------------------------------------------------------*
** --> QUEUE *
**---------------------------------------------------------------------*
*FORM QUEUE_CLOSE USING QUEUE.
* ROLLBACK WORK.
* CALL FUNCTION 'QUEUE_CLOSE'
* EXPORTING
* NAME = QUEUE
** OPENMODE = ' '
** QERASE = ' '
* QSTATE = ' '
** IMPORTING
** SQLRC =
* EXCEPTIONS
* INVALID_PARAMETER = 1
* Q_ERROR = 2
* SCHEDULE_PROBLEM = 3
* SQL_ERROR = 4
* OTHERS = 5.
* IF SY-SUBRC NE 0.
* MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
* ENDIF.
* COMMIT WORK.
*ENDFORM.

**---------------------------------------------------------------------*
** FORM QUEUE_DELETE *
**---------------------------------------------------------------------*
** ........ *
**---------------------------------------------------------------------*
** --> QUEUE *
** --> UNIT *
**---------------------------------------------------------------------*
*FORM QUEUE_DELETE USING QUEUE UNIT.
* CALL FUNCTION 'QUEUE_DELETE'
* EXPORTING
* NAME = QUEUE
* UNIT = UNIT
** IMPORTING
** SQLRC =
* EXCEPTIONS
* INVALID_PARAMETER = 1
* Q_ERROR = 2
* SQL_ERROR = 3
* OTHERS = 4.
* IF SY-SUBRC NE 0.
* MESSAGE ID SY-MSGID TYPE 'E' NUMBER SY-MSGNO
* WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
* ENDIF.
* COMMIT WORK.
*ENDFORM.

*---------------------------------------------------------------------*
* FORM PROCESS_UNIT *
*---------------------------------------------------------------------*
* ........ *
*---------------------------------------------------------------------*
* --> QUEUE *
* --> UNIT *
* --> BUFFER *
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
*---------------------------------------------------------------------*
* FORM PROCESS_UNIT *
*>>>> END OF INSERTION <<<<<<
...
DATA: CFBC_STRING LIKE TOA_CFBC,
F_CARA LIKE TOA_CARA,
F_CFBA LIKE TOA_CFBA,
F_CGDA LIKE TOA_CGDA.

*>>>> START OF DELETION <<<<<
DATA: MESSAGE(5).
DATA: FILENAME LIKE SAPB-SAPPFAD,
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
data: filename like sapb-sappfad,
*>>>> END OF INSERTION <<<<<<
...
IF QUEUE NE 'CFBC_E'.
PERFORM QUEUE_TRANSFER USING 'CFBC_E' BUFFER.
ENDIF.
MESSAGE ID SY-MSGID TYPE 'I' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*>>>> START OF DELETION <<<<<
MESSAGE S055 WITH QUEUE 'CFBC_E'.
ENDIF.
* 'CARA' or 'CARA_E'.
ELSEIF QUEUE EQ 'CARA' OR QUEUE EQ 'CARA_E'.
MOVE BUFFER TO F_CARA.
*******************************************************************
* old way or new way 50 GSC
*******************************************************************
data: f_toars like toars.
data: answer like sy-subrc. clear answer.
clear f_toars.
select * from toars into f_toars.endselect.
* nothing customized, so go the new way (Default)
if sy-subrc <> 0.
perform process_queue_cara_wo using 'CARA' unit f_cara answer.
exit.
* old way is not activated, so go the new way
elseif f_toars-oldway <> 'X'.

perform process_queue_cara_wo using 'CARA' unit f_cara answer.
exit.
else.
* continue with the old way
endif.
************************************************************************
* end of 50a: old or new way
************************************************************************





* PERFORM GET_FILE_NAME(OAALL) USING F_CARA-S_PATH 'spool'
* F_CARA-ARCHIV_ID CHANGING FILENAME.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
message s055(oa) with queue 'CFBC_E'.
ENDIF.
* 'CARA' or 'CARA_E'.
ELSEIF QUEUE EQ 'CARA' OR QUEUE EQ 'CARA_E'.
MOVE BUFFER TO F_CARA.
* old way or new way 50 GSC
data: f_toars like toars.
data: answer like sy-subrc.
perform get_toars changing f_toars.
if f_toars-oldway <> 'X'.
perform process_queue_cara_wo using 'CARA' unit f_cara answer.
exit.
endif.

* continue with the old way

*>>>> END OF INSERTION <<<<<<
...
CALL FUNCTION 'ARCHIV_CREATE_CARA_REQUEST'
EXPORTING
ARCHIV_ID = F_CARA-ARCHIV_ID
DOCUMENT_TYPE = F_CARA-DOC_TYPE
MANDANT = F_CARA-MANDT
PATH = F_CARA-S_PATH
PATH_TO_ARCHIVE = FILENAME
SIGN = F_CARA-SIGN
ICC_ID = F_CARA-INTERFACE
PROTOCOL = F_CARA-PROTOCOL
RPC_PARTNER = F_CARA-RPC_HOST
RPC_SERVICE = F_CARA-RPC_SERVIC
VERSION = F_CARA-VERSION
AR_OBJECT = F_CARA-AR_OBJECT
SAP_OBJECT = F_CARA-SAP_OBJECT
EXCEPTIONS
ERROR_ARCHIV = 1
ERROR_COMMUNICATIONTABLE = 2
ERROR_KERNEL = 3
OTHERS = 1.
IF SY-SUBRC NE 0.
STATUS = SY-SUBRC.
MESSAGE ID SY-MSGID TYPE 'I' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
*>>>> START OF DELETION <<<<<
* CALL FUNCTION 'ARCHIV_UPDATE_STATUS'
* EXPORTING
* SPOOLID = F_CARA-SIGN
* STATUS = '2'
* ERRORKEY = MESSAGE
* EXCEPTIONS
* OTHERS = 1.
IF QUEUE NE 'CARA_E'.
PERFORM QUEUE_TRANSFER USING 'CARA_E' BUFFER.
MESSAGE S055 WITH UNIT 'CARA_E'.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
if queue ne 'CARA_E'.
perform queue_transfer using 'CARA_E' buffer.
message s055(oa) with unit 'CARA_E'.
*>>>> END OF INSERTION <<<<<<
...
STATUS = SY-SUBRC.
MESSAGE ID SY-MSGID TYPE 'I' NUMBER SY-MSGNO
WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
IF QUEUE NE 'CFBA_E'.
PERFORM QUEUE_TRANSFER USING 'CFBA_E' BUFFER.
*>>>> START OF DELETION <<<<<
MESSAGE S055 WITH UNIT 'CFBA_E'.
ENDIF.
ENDIF.
ENDIF.
ENDFORM.

**---------------------------------------------------------------------*
** FORM QUEUE_TRANSFER *
**---------------------------------------------------------------------*
** ........ *
**---------------------------------------------------------------------*
** --> QUEUE *
** --> BUFFER *
**---------------------------------------------------------------------*
*FORM QUEUE_TRANSFER USING QUEUE BUFFER.
* PERFORM QUEUE_OPEN USING QUEUE Q_WRITE.
* PERFORM QUEUE_PUT USING QUEUE BUFFER.
* PERFORM QUEUE_CLOSE USING QUEUE.
*ENDFORM.

include archivelink_queues.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
message s055(oa) with unit 'CFBA_E'.
ENDIF.
ENDIF.
ENDIF.
ENDFORM.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI02
*& Object header PROG ILQAPI02
*&---------------------------------------------------------------------*
*& END-OF-SELECTION
*&---------------------------------------------------------------------*
...
IF SY-SUBRC NE 0.
MESSAGE W227.
ENDIF.
ENDCASE.

*>>>> START OF DELETION <<<<<
INCLUDE ILQAPI01.

*>>>> END OF DELETION <<<<<<<
...
*&---------------------------------------------------------------------*
*& FORM SELECT_DATA
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
FORM SELECT_DATA.
REFRESH: X_CFBC, X_CARA, X_CFBA.
CLEAR: X_DATA, X_CFBC, X_CARA, X_CFBA.

*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_GET TABLES T_BUFFER USING QUEUE.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_GET(OAQUEUES) TABLES T_BUFFER USING QUEUE.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM USER_COMMAND
*&---------------------------------------------------------------------*
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-006.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
PERFORM QUEUE_DELETE USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-006.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
*>>>> END OF INSERTION <<<<<<
...
PERFORM ARCHIV_UPDATE_SPOOL(OAALL)
USING
SPACE
x_cara-sign(10) x_cara-sign+11(5)
'2000' "Auftrag wurde gelöscht
'OA645' space space.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_DELETE USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-006.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
PERFORM QUEUE_DELETE USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-008.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBC.
PERFORM PROCESS_UNIT USING
QUEUE X_CFBC-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CFBC' OR STAT EQ 0.
PERFORM QUEUE_DELETE USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBC.
PERFORM PROCESS_UNIT(OAQUEUES) USING
QUEUE X_CFBC-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CFBC' OR STAT EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-008.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
*>>>> END OF INSERTION <<<<<<
...
X_DATA = X_CARA.
* CALL FUNCTION 'ARCHIV_UPDATE_STATUS'
* EXPORTING
* ERRORKEY = 'OA645'
* PARAM1 = ' '
* PARAM2 = ' '
* SPOOLID = X_CARA-SIGN
* STATUS = '2'
* EXCEPTIONS
* NOT_FOUND = 1
* INV_RQID = 2
* INV_PJNUM = 3
* OTHERS = 4.
*>>>> START OF DELETION <<<<<
PERFORM PROCESS_UNIT USING
QUEUE X_CARA-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CARA' OR STAT EQ 0.
PERFORM QUEUE_DELETE USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM PROCESS_UNIT(OAQUEUES) USING
QUEUE X_CARA-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CARA' OR STAT EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF ANSWER <> '1'.
EXIT.
ENDIF.
ENDIF.
X_DATA = X_CFBA.
*>>>> START OF DELETION <<<<<
PERFORM PROCESS_UNIT USING
QUEUE X_CFBA-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CFBA' OR STAT EQ 0.
PERFORM QUEUE_DELETE USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM PROCESS_UNIT(OAQUEUES) USING
QUEUE X_CFBA-UNIT X_DATA-BUFFER-S_BUFFER STAT.
IF QUEUE EQ 'CFBA' OR STAT EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDIF.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-007.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_OPEN USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBC.
PERFORM QUEUE_PUT USING TQUEUE X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
PERFORM QUEUE_CLOSE USING TQUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_OPEN(OAQUEUES) USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBC.
PERFORM QUEUE_PUT(OAQUEUES) USING TQUEUE
X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBC-UNIT.
DELETE X_CFBC.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
PERFORM QUEUE_CLOSE(OAQUEUES) USING TQUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-007.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_OPEN USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CARA.
PERFORM QUEUE_PUT USING TQUEUE X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
PERFORM QUEUE_CLOSE USING TQUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_OPEN(OAQUEUES) USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CARA.
PERFORM QUEUE_PUT(OAQUEUES) USING TQUEUE
X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CARA-UNIT.
DELETE X_CARA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
PERFORM QUEUE_CLOSE(OAQUEUES) USING TQUEUE.
*>>>> END OF INSERTION <<<<<<
...
IF SELFIELD-REFRESH <> 'X'.
PERFORM POPUP_TO_CONFIRM USING ANSWER TEXT-007.
IF ANSWER <> '1'.
EXIT.
ENDIF.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_OPEN USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBA.
PERFORM QUEUE_PUT USING TQUEUE X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE USING QUEUE.
PERFORM QUEUE_CLOSE USING TQUEUE.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_OPEN(OAQUEUES) USING TQUEUE 'W'.
SELFIELD-REFRESH = 'X'.
ENDIF.
X_DATA = X_CFBA.
PERFORM QUEUE_PUT(OAQUEUES) USING TQUEUE
X_DATA-BUFFER-S_BUFFER.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE X_CFBA-UNIT.
DELETE X_CFBA.
ENDLOOP.
IF SELFIELD-REFRESH = 'X'.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
PERFORM QUEUE_CLOSE(OAQUEUES) USING TQUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& AT USER-COMMAND
*&---------------------------------------------------------------------*
...
IF SY-SUBRC <> 0.
MESSAGE ID SY-MSGID TYPE 'I' NUMBER SY-MSGNO.
EXIT.
ENDIF.
WHEN 'DELE'.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
*>>>> END OF INSERTION <<<<<<
...
WHEN 'CFBC'.
PERFORM ARCHIV_UPDATE_STATUS(OAALL)
USING X_CARA-SIGN
'2000' "Auftrag wurde gelöscht
'OA645' space space.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_DELETE USING QUEUE UNIT.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
*>>>> END OF INSERTION <<<<<<
...
PERFORM ARCHIV_UPDATE_SPOOL(OAALL)
USING
SPACE
x_cara-sign(10) x_cara-sign+11(5)
'2000' "Auftrag wurde gelöscht
'OA645' space space.
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_DELETE USING QUEUE UNIT.
DELETE X_CARA INDEX SELFIELD-TABINDEX.
WHEN 'CFBA'.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
DELETE X_CARA INDEX SELFIELD-TABINDEX.
WHEN 'CFBA'.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
*>>>> END OF INSERTION <<<<<<
...
DELETE X_CFBA INDEX SELFIELD-TABINDEX.
ENDCASE.
SELFIELD-TABINDEX = 0.
SELFIELD-REFRESH = 'X'.
when 'PROC'.
*>>>> START OF DELETION <<<<<
perform queue_open using queue 'R'.
PERFORM PROCESS_UNIT USING QUEUE UNIT X_DATA-BUFFER-S_BUFFER STAT.
if queue eq 'CFBC' or queue eq 'CARA' or queue eq 'CFBA'
OR STAT EQ 0.
perform queue_delete using queue unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform queue_open(OAQUEUES) using queue 'R'.
PERFORM PROCESS_UNIT(OAQUEUES)
USING QUEUE UNIT X_DATA-BUFFER-S_BUFFER STAT.
if queue eq 'CFBC' or queue eq 'CARA' or queue eq 'CFBA'
OR STAT EQ 0.
perform queue_delete(OAQUEUES) using queue unit.
*>>>> END OF INSERTION <<<<<<
...
DELETE X_CFBA INDEX SELFIELD-TABINDEX.
ENDCASE.
SELFIELD-TABINDEX = 0.
SELFIELD-REFRESH = 'X'.
endif.
*>>>> START OF DELETION <<<<<
perform queue_close using queue.
when 'TRAN'.
PERFORM QUEUE_TRANSFER USING TQUEUE X_DATA-BUFFER-S_BUFFER.
perform queue_open using queue 'R'.
perform queue_delete using queue unit.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform queue_close(OAQUEUES) using queue.
when 'TRAN'.
PERFORM QUEUE_TRANSFER(OAQUEUES) USING TQUEUE
X_DATA-BUFFER-S_BUFFER.
perform queue_open(OAQUEUES) using queue 'R'.
perform queue_delete(OAQUEUES) using queue unit.
*>>>> END OF INSERTION <<<<<<
...
WHEN 'CFBC' OR 'CFBC_E'.
DELETE X_CFBC INDEX SELFIELD-TABINDEX.
WHEN 'CFBA' OR 'CFBA_E'.
DELETE X_CFBA INDEX SELFIELD-TABINDEX.
ENDCASE.
*>>>> START OF DELETION <<<<<
perform queue_close using queue.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform queue_close(OAQUEUES) using queue.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI20
*& Object header PROG ILQAPI20
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI20
*&---------------------------------------------------------------------*
...
include archivelink_caraconstants.
include archivelink_queuedeclarations.

* Imaging-Variablen
DATA: CFBC_STRING LIKE TOA_CFBC.
*>>>> START OF DELETION <<<<<
*DATA: BEGIN OF T_BUFFER OCCURS 1,
* UNIT LIKE APQD-TRANS,
* S_BUFFER(1000),
* END OF T_BUFFER.
*DATA: UNIT LIKE APQD-TRANS.

PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_GET TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR CFBC_STRING.
MOVE T_BUFFER-S_BUFFER TO CFBC_STRING.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT USING QUEUE UNIT CFBC_STRING STATUS.
IF QUEUE NE 'CFBC_E'.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CFBC_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE USING QUEUE.

INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<

PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_GET(OAQUEUES) TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR CFBC_STRING.
MOVE T_BUFFER-S_BUFFER TO CFBC_STRING.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT(OAQUEUES) USING QUEUE UNIT CFBC_STRING STATUS.
IF QUEUE NE 'CFBC_E'.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CFBC_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI21
*& Object header PROG ILQAPI21
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI21
*&---------------------------------------------------------------------*
...
CFBC_STRING-ARC_DOC_ID = ARC_DOC_.
CFBC_STRING-RET_CODE = RET_CODE.

MOVE CFBC_STRING TO BUFFER.
* Put Data into Queue *
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT USING QUEUE BUFFER.
ENDDO.
PERFORM QUEUE_CLOSE USING QUEUE.

INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT(OAQUEUES) USING QUEUE BUFFER.
ENDDO.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI40
*& Object header PROG ILQAPI40
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI40
*&---------------------------------------------------------------------*
...
PROGRAM ILQAPI40 MESSAGE-ID OA.
*----------------------------------------------------------------------*
* Q-API Driver Program for Optical Archiving Queue CARA *
* (c) Copyright SAP AG 1992 *
*----------------------------------------------------------------------*
INCLUDE LOPTACON. " Imaging defines
PARAMETERS: QUEUE LIKE APQI-QID DEFAULT 'CARA'.
*>>>> START OF DELETION <<<<<
************************************************************************
* 50a GSC: old way or new way
************************************************************************
***
include archivelink_caraconstants.
include archivelink_queuedeclarations.
***
*data: f_toars like toars.
clear f_toars.
select * from toars into f_toars.endselect.
* nothing customized, so go the new way (Default)
if sy-subrc <> 0.
submit archivelink_cara with queue = queue.
exit.
* old way is not activated, so go the new way
elseif f_toars-oldway <> 'X'.
submit archivelink_cara with queue = queue.
exit.
else.
* continue with the old way
endif.
************************************************************************
* end of 50a: old or new way
************************************************************************




*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
include archivelink_caraconstants.
include archivelink_queuedeclarations.
***
data: f_toars like toars.

* 50a GSC: old way or new way
perform get_toars(oaqueues) changing f_toars.
* old way is not activated, so go the new way
if f_toars-oldway <> 'X'.
submit archivelink_cara with queue = queue.
exit.
endif.

* continue with the old way


*>>>> END OF INSERTION <<<<<<
...
DATA: F_CARA LIKE TOA_CARA.

*DATA: BEGIN OF T_BUFFER OCCURS 1,
* UNIT LIKE APQD-TRANS,
* S_BUFFER(1000),
* END OF T_BUFFER.
*DATA: UNIT LIKE APQD-TRANS.

*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_GET TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR F_CARA.
MOVE T_BUFFER-S_BUFFER TO F_CARA.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT USING QUEUE UNIT F_CARA STATUS.
IF QUEUE NE 'CARA_E'.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CARA_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE USING QUEUE.

INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_GET(OAQUEUES) TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR F_CARA.
MOVE T_BUFFER-S_BUFFER TO F_CARA.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT(OAQUEUES) USING QUEUE UNIT F_CARA STATUS.
IF QUEUE NE 'CARA_E'.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CARA_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI41
*& Object header PROG ILQAPI41
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI41
*&---------------------------------------------------------------------*
...
CALL FUNCTION 'ARCHIV_APPLICATIONINFO_GET'
EXPORTING
SAP_OBJECT = S_OBJECT
AR_OBJECT = AR_OBJEC
IMPORTING
INTERFACE = I_CARA-INTERFACE
ARCHIV_ID = I_CARA-ARCHIV_ID
DOCUMENT_TYPE = I_CARA-DOC_TYPE
PATH = I_CARA-S_PATH
RPC_HOST = I_CARA-RPC_HOST
RPC_SERVICE = I_CARA-RPC_SERVIC
VERSION = I_CARA-VERSION
PROTOKOLL = I_CARA-PROTOCOL
EXCEPTIONS
OTHERS = 1.

MOVE I_CARA TO BUFFER.
* Put Data into Queue *
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT USING QUEUE BUFFER.
ENDDO.
PERFORM QUEUE_CLOSE USING QUEUE.
INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT(OAQUEUES) USING QUEUE BUFFER.
ENDDO.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI60
*& Object header PROG ILQAPI60
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI60
*&---------------------------------------------------------------------*
...
DATA: CFBA_STRING LIKE TOA_CFBA.
*DATA: BEGIN OF T_BUFFER OCCURS 1,
* UNIT LIKE APQD-TRANS,
* S_BUFFER(1000),
* END OF T_BUFFER.
*DATA: UNIT LIKE APQD-TRANS.

*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_GET TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR CFBA_STRING.
MOVE T_BUFFER-S_BUFFER TO CFBA_STRING.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT USING QUEUE UNIT CFBA_STRING STATUS.
IF QUEUE NE 'CFBA_E'.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CFBA_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE USING QUEUE.

INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_GET(OAQUEUES) TABLES T_BUFFER USING QUEUE.
LOOP AT T_BUFFER.
CLEAR CFBA_STRING.
MOVE T_BUFFER-S_BUFFER TO CFBA_STRING.
MOVE T_BUFFER-UNIT TO UNIT.
PERFORM PROCESS_UNIT(OAQUEUES) USING QUEUE UNIT CFBA_STRING STATUS.
IF QUEUE NE 'CFBA_E'.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ELSEIF QUEUE EQ 'CFBA_E' AND STATUS EQ 0.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE UNIT.
ENDIF.
ENDLOOP.
PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQAPI61
*& Object header PROG ILQAPI61
*&---------------------------------------------------------------------*
*& PROGRAM ILQAPI61
*&---------------------------------------------------------------------*
...
CFBA_STRING-TARGETPATH = PFAD.

*----------------------------------------------------------------------*
* Put Data into Queue *
*----------------------------------------------------------------------*
BUFFER = CFBA_STRING.
* Put Data into Queue *
*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT USING QUEUE BUFFER.
ENDDO.

PERFORM QUEUE_CLOSE USING QUEUE.

INCLUDE ILQAPI01. " QAPI Defines
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'W'.
DO TESTLOOP TIMES.
PERFORM QUEUE_PUT(OAQUEUES) USING QUEUE BUFFER.
ENDDO.

PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS ILQTRANS
*& Object header PROG ILQTRANS
*&---------------------------------------------------------------------*
*& REPORT ILQTRANS
*&---------------------------------------------------------------------*
...
WHEN 'CARA_E'. DEST_QUEUE = 'CARA'.
WHEN 'CFBA_E'. DEST_QUEUE = 'CFBA'.
WHEN OTHERS. EXIT.
ENDCASE.

*>>>> START OF DELETION <<<<<
PERFORM QUEUE_OPEN USING QUEUE 'R'.
PERFORM QUEUE_OPEN USING DEST_QUEUE 'W'.

PERFORM QUEUE_GET TABLES BUFFER USING QUEUE.
LOOP AT BUFFER.
IF DEL_ONLY <> 'X'.
PERFORM QUEUE_PUT USING DEST_QUEUE BUFFER-S_BUFFER.
ENDIF.
PERFORM QUEUE_DELETE USING QUEUE BUFFER-UNIT.
ENDLOOP.

PERFORM QUEUE_CLOSE USING QUEUE.
PERFORM QUEUE_CLOSE USING DEST_QUEUE.

INCLUDE ILQAPI01.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
PERFORM QUEUE_OPEN(OAQUEUES) USING QUEUE 'R'.
PERFORM QUEUE_OPEN(OAQUEUES) USING DEST_QUEUE 'W'.

PERFORM QUEUE_GET(OAQUEUES) TABLES BUFFER USING QUEUE.
LOOP AT BUFFER.
IF DEL_ONLY <> 'X'.
PERFORM QUEUE_PUT(OAQUEUES) USING DEST_QUEUE BUFFER-S_BUFFER.
ENDIF.
PERFORM QUEUE_DELETE(OAQUEUES) USING QUEUE BUFFER-UNIT.
ENDLOOP.

PERFORM QUEUE_CLOSE(OAQUEUES) USING QUEUE.
PERFORM QUEUE_CLOSE(OAQUEUES) USING DEST_QUEUE.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS LOPTRF02
*& Object header FUGR OPTR
*&---------------------------------------------------------------------*
*& FORM TOGGLE_OLD_NEW_PROCESSING
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
*----------------------------------------------------------------------*
***INCLUDE LOPTRF02 .
*----------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Form toggle_old_new_processing
*&---------------------------------------------------------------------*
* text
*----------------------------------------------------------------------*
* --> p1 text
* <-- p2 text
*----------------------------------------------------------------------*
FORM toggle_old_new_processing.
data: f_toars like toars. clear f_toars.
select * from toars into f_toars. endselect.
* no entry
if sy-subrc <> 0.
f_toars-oldway = 'X'.
insert into toars values f_toars.
else.
if f_toars-oldway = 'X'.
f_toars-oldway = space.
else.
f_toars-oldway = 'X'.
endif.
delete from toars.
insert into toars values f_toars.
endif.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
*&---------------------------------------------------------------------*
*& Form toggle_old_new_processing
*&---------------------------------------------------------------------*
FORM toggle_old_new_processing.
data: f_toars like toars.
perform get_toars(oaqueues) changing f_toars.
perform toggle_value using f_toars-oldway.
perform set_toars(oaqueues) using f_toars.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TOGGLE_NEW_CARA
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form toggle_new_cara
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* --> p1 text
* <-- p2 text
*----------------------------------------------------------------------*
FORM toggle_new_cara.
data: f_toars like toars. clear f_toars.
select * from toars into f_toars. endselect.
* no entry
if sy-subrc <> 0.
f_toars-caradebug = 'X'.
insert into toars values f_toars.
else.
if f_toars-caradebug = 'X'.
f_toars-caradebug = space.
else.
f_toars-caradebug = 'X'.
endif.
delete from toars.
insert into toars values f_toars.
endif.

ENDFORM. " toggle_new_cara
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
FORM toggle_new_cara.
data: f_toars like toars.
perform get_toars(oaqueues) changing f_toars.
perform toggle_value using f_toars-caradebug.
perform set_toars(oaqueues) using f_toars.
ENDFORM. " toggle_new_cara

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TOGGLE_NEW_CFBC
*&---------------------------------------------------------------------*
...
*---------------------------------------------------------------------*
* FORM toggle_new_cfbc *
*---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* ........ *
*---------------------------------------------------------------------*
FORM toggle_new_cfbc.
data: f_toars like toars. clear f_toars.
select * from toars into f_toars. endselect.
* no entry
if sy-subrc <> 0.
f_toars-cfbcdebug = 'X'.
insert into toars values f_toars.
else.
if f_toars-cfbcdebug = 'X'.
f_toars-cfbcdebug = space.
else.
f_toars-cfbcdebug = 'X'.
endif.
delete from toars.
insert into toars values f_toars.
endif.

ENDFORM. " toggle_new_cara
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
FORM toggle_new_cfbc.
data: f_toars like toars.
perform get_toars(oaqueues) changing f_toars.
perform toggle_value using f_toars-cfbcdebug.
perform set_toars(oaqueues) using f_toars.
ENDFORM. " toggle_new_cara

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TOGGLE_NEW_AUTODELETION
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form toggle_new_autodeletion
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* --> p1 text
* <-- p2 text
*----------------------------------------------------------------------*
FORM toggle_new_autodeletion.
data: f_toars like toars. clear f_toars.
select * from toars into f_toars. endselect.
* no entry
if sy-subrc <> 0.
f_toars-nodeletion = 'X'.
insert into toars values f_toars.
else.
if f_toars-nodeletion = 'X'.
f_toars-nodeletion = space.
else.
f_toars-nodeletion = 'X'.
endif.
delete from toars.
insert into toars values f_toars.
endif.


ENDFORM. " toggle_new_autodeletion
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
FORM toggle_new_autodeletion.
data: f_toars like toars.
perform get_toars(oaqueues) changing f_toars.
perform toggle_value using f_toars-nodeletion.
perform set_toars(oaqueues) using f_toars.
ENDFORM. " toggle_new_autodeletion

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM GIVE_ME_ERROR_COUNTS
*&---------------------------------------------------------------------*
...
*&---------------------------------------------------------------------*
*& Form give_me_error_counts
*&---------------------------------------------------------------------*
*>>>> START OF DELETION <<<<<
* text
*----------------------------------------------------------------------*
* -->P_CARFCOUNT text
* -->P_CFBFCOUNT text
*----------------------------------------------------------------------*
FORM give_me_error_counts USING CARa
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
FORM give_me_error_counts USING CARa
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& FORM TOGGLE_VALUE
*&---------------------------------------------------------------------*
*>>>> START OF INSERTION <<<<
*----------------------------------------------------------------------*
***INCLUDE LOPTRF02 .
*----------------------------------------------------------------------*

*&---------------------------------------------------------------------*
*& Form toggle_value
*&---------------------------------------------------------------------*
form toggle_value changing value type c.
if value = 'X'.
value = space.
else.
value = 'X'.
endif.
endform.

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS LOPTRO01
*& Object header FUGR OPTR
*&---------------------------------------------------------------------*
*& MODULE D500_OUTPUT OUTPUT
*&---------------------------------------------------------------------*
...
f_toamo-r_cara = caracount.
f_toamo-r_cfbc = cfbccount.
f_toamo-e_cara = carfcount.
f_toamo-e_cfbc = cfbfcount.
* settings
*>>>> START OF DELETION <<<<<
select * from toars into f_toars. endselect.
if sy-subrc <> 0.
newcaraactive = text-034.
caradebug = text-037.
cfbcdebug = text-037.
deletefinished = text-038.
else.
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
perform get_toars(oaqueues) changing f_toars.
*>>>> END OF INSERTION <<<<<<
...
endif.
if f_toars-nodeletion = 'X'.
deletefinished = text-039.
else.
deletefinished = text-038.
*>>>> START OF DELETION <<<<<
endif.
endif.
* end of new CARA 50 GSC
*>>>> END OF DELETION <<<<<<<
*>>>> START OF INSERTION <<<<
endif.
* end of new CARA 50 GSC
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*&---------------------------------------------------------------------*
*& Object REPS OAQUEUES
*& Object header PROG OAQUEUES
*&---------------------------------------------------------------------*
*>>>> START OF INSERTION <<<<
*&---------------------------------------------------------------------*
*& Subroutinenpool OAQUEUES
*&---------------------------------------------------------------------*

*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*
*& PROGRAM OAQUEUES
*&---------------------------------------------------------------------*
...
PROGRAM OAQUEUES .
*>>>> START OF INSERTION <<<<


include rsqapidf. " QAPI Defines
include ARCHIVELINK_CARACONSTANTS.
include ARCHIVELINK_QUEUEDECLARATIONS.
include ARCHIVELINK_QUEUES.
include ILQAPI01.
*>>>> END OF INSERTION <<<<<<
...
*&---------------------------------------------------------------------*

Effected Objects:


(REPS) - ARCHIVELINKCARAHTTP
(REPS) - ARCHIVELINK_CARA
(REPS) - ARCHIVELINK_CARACONSTANTS
(REPS) - ARCHIVELINK_CFBC
(REPS) - ARCHIVELINK_MONITOR_ASYNC
(REPS) - ARCHIVELINK_QUEUEDECLARATIONS
(REPS) - ARCHIVELINK_QUEUES
(REPS) - ILQAPI01
(REPS) - ILQAPI02
(REPS) - ILQAPI20
(REPS) - ILQAPI21
(REPS) - ILQAPI40
(REPS) - ILQAPI41
(REPS) - ILQAPI60
(REPS) - ILQAPI61
(REPS) - ILQTRANS
(REPS) - LOPTRF02
(REPS) - LOPTRO01
(REPS) - OAQUEUES

(REPS) - ARCHIVELINKCARAHTTP
(REPS) - ARCHIVELINK_CARA
(REPS) - ARCHIVELINK_CARACONSTANTS
(REPS) - ARCHIVELINK_CFBC
(REPS) - ARCHIVELINK_MONITOR_ASYNC
(REPS) - ARCHIVELINK_QUEUEDECLARATIONS
(REPS) - ARCHIVELINK_QUEUES
(REPS) - ILQAPI01
(REPS) - ILQAPI02
(REPS) - ILQAPI20
(REPS) - ILQAPI21
(REPS) - ILQAPI40
(REPS) - ILQAPI41
(REPS) - ILQAPI60
(REPS) - ILQAPI61
(REPS) - ILQTRANS
(REPS) - LOPTRF02
(REPS) - LOPTRO01
(REPS) - OAQUEUES

Solution instructions


Please import the corrections attached to this OSS note into your SAP system using SNOTE.

You can also view the full details of this OSS note and download it to your SAP system ready for implementation using transaction code SNOTE. Once it has been downloaded you can read the full details, check out any installation instructions including manual changes and see if there are any pre-requisites.

You can also check if a new version of note 609541 has been released as well as see if the note is valid for your current SAP system landscape.

Check if SAP OSS note 609541 has already been downloaded and is valid


To check if this note has already been download, what status it has and if it is valid for your system first execute t-code SNOTE and click on the SAP Note Browser icon
Icon used to execute SAP Note Browser report within SNOTE

From here you can just enter the note number 609541 and press execute. If the note already exists it's details will be displayed. See here for full step by step instructions on how to check if an SAP note has been downloaded and is valid for your system.



If note 609541 does not exist on your system you will receive the message "Unable to find SAP Note that meets specified criteria"
Icon used to execute SAP Note Browser report within SNOTE

If this is the case you will need to download the note to you SAP system also using transaction SNOTE. For further details see Download note using SNOTE. Even if it does exist you may still want to check if you have downloaded the latest version of the note.

Alternatively you can find full details of this note on the SAP service market place(SNumber / Service market place login will be required)