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

Batch input in background

Former Member
0 Likes
790

Hi. I've a BI session created in the SM35 and i want to execute it in background using the following

code:

CALL FUNCTION 'JOB_OPEN'

EXPORTING

jobname = v_jobname

sdlstrtdt = sy-datum

sdlstrttm = sy-uzeit

IMPORTING

jobcount = v_jobcount

SUBMIT rsbdcbtc

USER sy-uname

VIA JOB v_jobname NUMBER v_jobcount

WITH queue-id = v_qid

WITH mappe = v_jobname

WITH modus = 'N'

AND RETURN.

IF sy-subrc EQ 0.

CALL FUNCTION 'JOB_CLOSE'

EXPORTING

jobcount = v_jobcount

jobname = v_jobname

strtimmed = 'X'

IMPORTING

job_was_released = v_jobliberado

All the sy-subrc are ok, but when in the log's job there is the following message:

Job started

Step 001 started (program RSBDCBTC, variant &0000000000103, user ID T53274)

No session found with status "New" or "Error"

Job finished

Can anyone help me?

Thanks!

1 ACCEPTED SOLUTION
Read only

Former Member
0 Likes
544

I think it would be easier to just:

SUBMIT RSBDCSUB.

This will create a background job to submit the batch input session.

Rob

2 REPLIES 2
Read only

venkata_ramisetti
Active Contributor
0 Likes
544

Hi,

I think you have to use function module JOB_SUBMIT to submit the job.

I am not sure about this.

Thanks

Ramakrishna

Read only

Former Member
0 Likes
545

I think it would be easier to just:

SUBMIT RSBDCSUB.

This will create a background job to submit the batch input session.

Rob