Application Development 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: 

Report in background not create spool when no data found

Former Member
0 Kudos

Hello ,

I created simple rapport that should run in background. When I execute background job (sm37) I noticed that the spool exists only

for when the some data is found. When data is not found for any reason I do not have spool , and I need one saying

'records passed 0'. I am not sure what I can do about it. I saw insome programs that is possible but I cannot find how it was done. Please advice .

Krsto

2 REPLIES 2

nabheetscn
Active Contributor
0 Kudos

Hi,

when no record is found then write something tothe output.In this way spoolwill get created.

Thanks

Nabheet

Former Member
0 Kudos

Hi,

You might be checking if the Final Internal table has data in it or not (May be in END-OF-SELECTION). If you are not do have check on this and simple code a write statement like below.

IF IT_FINAL IS NOT INITIAL.

CREATING A SPOOL.

ELSE.

WRITE : / 'Records Passed are 0'.

ENDIF.

Let me know if you need any further help on this.

Regards,

SRinivas