‎2007 Oct 03 7:58 AM
hello experts
i am using the FM JOB_OPEN, followed by submit RFBIBL00.
unfortunately it is not creating any background task when i am checcking in the transaction SM35, inspite the sy-subrc eq 0.
can anyone help me out please.
thank you
regards
priya
‎2007 Oct 03 8:02 AM
hi,
u need to check sm36 and sm37 for background jobs.
sm35 is for sessions not background job
‎2007 Oct 03 8:03 AM
Hi
see the sample code and do accordingly
you are doing something wrong somewhere
IF p_bjob = 'X'.
CONCATENATE sy-cprog sy-datum sy-uzeit
INTO jobname SEPARATED BY '_'.
CALL FUNCTION 'JOB_OPEN'
EXPORTING
jobname = jobname
IMPORTING
jobcount = jobcount
EXCEPTIONS
cant_create_job = 1
invalid_job_data = 2
jobname_missing = 3
OTHERS = 4.
CALL FUNCTION 'GET_PRINT_PARAMETERS'
IMPORTING
out_archive_parameters = arc_params
out_parameters = print_params
valid = valid
EXCEPTIONS
archive_info_not_found = 1
invalid_print_params = 2
invalid_archive_params = 3
OTHERS = 4.
IF valid = chk.
SUBMIT ybrept
WITH s_devc IN s_devc
AND RETURN
USER sy-uname
VIA JOB jobname
NUMBER jobcount
TO SAP-SPOOL
SPOOL PARAMETERS print_params
ARCHIVE PARAMETERS arc_params
WITHOUT SPOOL DYNPRO.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
jobcount = jobcount
jobname = jobname
strtimmed = 'X'
EXCEPTIONS
cant_start_immediate = 1
invalid_startdate = 2
jobname_missing = 3
job_close_failed = 4
job_nosteps = 5
job_notex = 6
lock_failed = 7
invalid_target = 8
OTHERS = 9.
IF sy-subrc <> 0.
MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
ELSE.
MESSAGE i029 WITH jobname.
ENDIF.
ELSE.
MESSAGE s000 WITH text-003.
STOP.
ENDIF.
ENDIF.
Regards
Anji
‎2007 Oct 03 8:03 AM
RFBIBL00 wont work in Background.. SAP can upload files in background only from application server & not from presentation server.
Since the program would be raising a error message.. job is not generated.
‎2007 Oct 03 8:37 AM
thank you all for the helpfu replies.
i have checked in sm36, well it is being created, but then the status is 'cancelled' after having executed half way. any suggestions?
is there anything else i should use instead of RFBIBL00?
thank you
regards
priya
‎2007 Oct 03 8:39 AM
Hi Priya,
<b>RFBIBL00 wont work in Background..</b> SAP can upload files in background only from application server & not from presentation server.
Since the program would be raising a error message.. job is cancelled.
Double click on the error message & u will get the details.
RFBIBL00 can be executed only in foreground.
Best regards,
Prashant