09-15-2014 10:32 AM
Hi Experts,
I have a requirement wherein the End users will have to run a report in background mode because the amount of data is high.
The issue that im facing here is that the end users can schedule a background job but don't have the authorization to release it,
We also cannot assign the authorization to the end users.
So, Could there be a workaround where I can handle it programatically. i.e. If the end users execute that report in background ,we
can schedule and release the report programatically using some others username who has the access/authorization??
Please provide me your valuable inputs.
Thanks,
Faiz
09-15-2014 10:38 AM
You could create a periodic job that get the list of unreleased jobs and modify/release them depending on your exact requirement (Background Processing, Programming with the Background Processing System (BC-CCM-BTC), Background Processing Function Modules.)
Regards,
Raymond
09-15-2014 11:00 AM
Hi Raymond ,
As per your suggetsion Im trying to execute it in backround however Im getting an error : Maximin number of internal session reached.This possible is due to the recursice calling of the program by itself. How do I handle this.
SUBMIT (sy-cprog)
WITH s_matnr IN s_matnr
WITH s_attr IN s_attr
WITH s_date IN s_date
WITH s_time IN s_time
WITH s_crby IN s_crby
WITH s_chdby IN s_chdby
VIA JOB gv_job NUMBER gv_count AND RETURN
TO SAP-SPOOL WITHOUT SPOOL DYNPRO
DESTINATION sy-pdest
IMMEDIATELY lc_x
KEEP IN SPOOL lc_x.
CALL FUNCTION 'JOB_CLOSE'
EXPORTING
Thanks
Faiz
09-15-2014 11:05 AM
Faiz
A simple option can be you define a parameter on selection screen with no-display and when you are scheduling your program via submit simply pass this as X and when you get X just skip this call.
Out of curiosity you are scheduling the same program in background?
Nabheet