Skip to Content

Archived discussions are read-only. Learn more about SAP Q&A

Running job along with variant programatically

Hai,

I have to run a report (which have selection screen) through job from the module pool program.

that is the user will click on a button which triggers the execution of the report in back ground.

this report have a selection screen.I am creating the variant programatically & I have to use the same varinat in the job.But when I checked the job_open fm , it is not taking any input parametrs for variant.

please note creating the variant & job before the execution of the module pool program is not possible because I have to ceate the variant with the values from the module pool screen & I need to use the job

because the foreground process takes huge amount of time hence going for back ground.

can any one please tell how to cretae a job with varinat programatically?

creating a job with out variant is possible through job_open but I want to create a job with variant so that I can run the repor from module pool.

please give your ideas.

Regards,

Bhaskar.

Former Member
Former Member replied

Hello,

after the function JOB_OPEN you could use the submit_statment.

submit <Reportname> user <user> via job <jobname> number <jobnumber> using selection-set <variant>.

the jobname and jobnumber you would get from the JOB_OPEN-Function.

At last there would be a call function JOB_CLOSE or JOB_SUBMIT.

Regards Wolfgang

0 View this answer in context
Not what you were looking for? View more on this topic or Ask a question