Application Development and Automation Discussions
Join the discussions or start your own on all things application development, including tools and APIs, programming models, and keeping your skills sharp.
cancel
Showing results for 
Search instead for 
Did you mean: 
Read only

Submit to Spool not working

Former Member
0 Likes
819

I have a bdc that I'm automatically processing using a "Submit rsbdcsub" call and I want to get the bdc input log redirected to the spool. I'm using the below statement but it doesn't appear to be working.

The bdc processes successfully, and I'm able to view the bdc input log in SM35, but no spool is generated. If I look in SM37 for the job completion, it completes successfully, but there is no spool. How can I get the log output to redirect to the spool so it is visible in SM37? Any help is greatly appreciated.

CALL FUNCTION 'GET_PRINT_PARAMETERS'
     EXPORTING
       NO_DIALOG              = 'X'
     IMPORTING
       OUT_PARAMETERS         = LS_PARAM
     EXCEPTIONS
       ARCHIVE_INFO_NOT_FOUND = 1
       INVALID_PRINT_PARAMS   = 2
       INVALID_ARCHIVE_PARAMS = 3
       OTHERS                 = 4.
   LS_PARAM-PRIMM = SPACE.

* Submit the created BDC batch for background processing.
SUBMIT rsbdcsub TO SAP-SPOOL SPOOL PARAMETERS ls_param
   with mappe = 'ZABAA_OEB'  " Batch Name
   with fehler = ' '         " No Batch Sessions that are errored
   with von sy-datum
   with bis = sy-datum
   with z_verab = 'X'        " To Process
*  EXPORTING LIST TO MEMORY
   AND RETURN
   WITHOUT SPOOL DYNPRO.

I have a bdc that I'm automatically processing using a "Submit rsbdcsub" call and I want to get the bdc input log redirected to the spool. I'm using the below statement but it doesn't appear to be working.

The bdc processes successfully, and I'm able to view the bdc input log in SM35, but no spool is generated. If I look in SM37 for the job completion, it completes successfully, but there is no spool. How can I get the log output to redirect to the spool so it is visible in SM37? Any help is greatly appreciated.

CALL FUNCTION 'GET_PRINT_PARAMETERS'
     EXPORTING
       NO_DIALOG              = 'X'
     IMPORTING
       OUT_PARAMETERS         = LS_PARAM
     EXCEPTIONS
       ARCHIVE_INFO_NOT_FOUND = 1
       INVALID_PRINT_PARAMS   = 2
       INVALID_ARCHIVE_PARAMS = 3
       OTHERS                 = 4.
   LS_PARAM-PRIMM = SPACE.

* Submit the created BDC batch for background processing.
SUBMIT rsbdcsub TO SAP-SPOOL SPOOL PARAMETERS ls_param
   with mappe = 'ZABAA_OEB'  " Batch Name
   with fehler = ' '         " No Batch Sessions that are errored
   with von sy-datum
   with bis = sy-datum
   with z_verab = 'X'        " To Process
*  EXPORTING LIST TO MEMORY
   AND RETURN
   WITHOUT SPOOL DYNPRO.

2 REPLIES 2
Read only

gouravkumar64
Active Contributor
0 Likes
591

hi,

this link may be helpful,

<removed by moderator>

Moderator message: please refrain from posting only link(s) without additional information about why they are relevant to the problem.

Message was edited by: Thomas Zloch

Read only

0 Likes
591

Thanx for the reply but my issue is not how to output it to a spool...It's how to output it to a spool that belongs to a secondary background job. For example, my program A generates the bdc records to get them ready for processing. It then uses the SUBMIT rsbdcsub call to launch a background process to process the created bdc records. My program A is complete once the background job is launched, so I have no log data to loop through until the background job is finished.

The batch input log is generated upon completion of the background job and can be viewed in sm35...my question is how can I attach this log as a spool so it is visible to the end user in SM37? Remembering that the program that generates the actual log is not controlled by me...just launched by my program.

Does that make sense?