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

Report in Background

Former Member
0 Likes
983

Hi,

I have created a report. Selected all the data I require to pass to SAP Spool. I have all the data in Final Internal Table. Can anybody suggest how can i make this report to run in background. where I have to use FM's JOB_OPEN,JOB_SUBMIT,JOB_CLOSE in my report. Is it before the data selection. PLease suggest.

I need to understand the proper sequence of these FM's in my report.

Thanks,

VB

Hi,

I have created a report. Selected all the data I require to pass to SAP Spool. I have all the data in Final Internal Table. Can anybody suggest how can i make this report to run in background. where I have to use FM's JOB_OPEN,JOB_SUBMIT,JOB_CLOSE in my report. Is it before the data selection. PLease suggest.

I need to understand the proper sequence of these FM's in my report.

Thanks,

VB

7 REPLIES 7
Read only

former_member209818
Active Contributor
0 Likes
939

Seems you are confused. If you have already selected all the data which you want in spool, then why don't you show all those details as a output of your own report and schedule that report in the background.?

The FM you are referring are mainly used for scheduling some background job. Support from program A you want to schedule a program B based on some condtions. Then you will call those FMs in Prog A to schedule the program B.

Read only

Former Member
0 Likes
939

Background jobs are created using transaction SM36 and monitored using transaction SM37.

Get in touch with Basis guy to create a batch job.

Read only

Former Member
0 Likes
939

Hi Vikas,

When you have all the data ready, just use REUSE_ALV_GRID_DISPLAY to show it as output. Then, execute the report in background. It will automatically create the spool and you can view your output in SP01.

Regards,

Sindhu Pulluru.

Read only

0 Likes
939

In my last system REUSE_ALV_GRID_DISPLAY wont create a spool. Go for REUSE_ALV_LIST_DISPLAY. Not sure if the FM is modified or it was bug in our system.

Read only

0 Likes
939

Hi Chinmay,

May be you are true...But, I just used the same logic for one of my reports last week and I was able to create a spool with REUSE_ALV_GRID_DISPLAY.

Regards,

Sindhu Pulluru.

Read only

RaymondGiuseppi
Active Contributor
0 Likes
939

I'm not sure to understand you, the following trick will trigger background execution before start-of-selection.

AT SELECTION-SCREEN.

  CASE sscrfields-ucomm.

    WHEN 'ONLI' OR 'PRIN'.

        " You can add some checks here e.g. if a select-options is empty

        sscrfields-ucomm = 'SJOB'.

      ENDIF.

  ENDCASE.

Regards,

Raymond

Read only

Former Member
0 Likes
939

no need for job open close etc...

just use reuse_alv grid to display your report

on reuse alv parameters (is_print parameter)

is_print-no_print_listinfos = 'X'.

after scheduling your report, it will directly send to spool (se38->program->execute->background->schedule)