Problem submitting a report in back ground

Hi,
I'm trying to submit a report in background and I always get an error saying make an entry in all required fields. But it works perfectly fine in foreground. I'm not sure what am I doing wrong. Pls suggest.............I'm not using any front end FMs...
  SUBMIT RKAEP000 via selection-screen
         USING SELECTION-SCREEN 310
         with p_tcode eq 'KOB2'
         WITH  SELECTION-TABLE seltab
         TO SAP-SPOOL WITHOUT SPOOL DYNPRO
         AND RETURN.

Hi chesat
u just compare ur code with this...
Using JOB_OPEN,JOB_SUBMIT,JOB_CLOSE
Demo Program:
REPORT  YJob  .
DATA : v_jobhead LIKE tbtcjob.
DATA : v_jobcount LIKE tbtcjob-jobcount.
DATA : v_eventparm LIKE tbtcjob-eventparm.
DATA : v_flg_released TYPE c.
DATA: e_error.
DATA: running LIKE tbtcv-run.
TYPES: esp1_boolean LIKE boole-boole.
CONSTANTS: esp1_false TYPE esp1_boolean VALUE ' ',
           esp1_true  TYPE esp1_boolean VALUE 'X'.
CONSTANTS: true  TYPE boolean VALUE esp1_true,
                          false TYPE boolean VALUE esp1_false.
PARAMETERS: v_jobnam LIKE tbtcjob-jobname,
            v_report LIKE sy-repid,
            v_varian LIKE  raldb-variant,
            v_uname  LIKE sy-uname.
START-OF-SELECTION.
add the new job
  CALL FUNCTION 'JOB_OPEN'
       EXPORTING
           delanfrep        = 'X'
            jobname          = v_jobnam
       IMPORTING
            jobcount         = v_jobcount
       EXCEPTIONS
            cant_create_job  = 1
            invalid_job_data = 2
            jobname_missing  = 3
            OTHERS           = 4.
  IF sy-subrc <> 0.
    e_error = true.
  ELSE.
    CALL FUNCTION 'JOB_SUBMIT'
         EXPORTING
              authcknam               = v_uname
              jobcount                = v_jobcount
              jobname                 = v_jobnam
              report                  = v_report
              variant                 = v_varian
         EXCEPTIONS
              bad_priparams           = 1
              bad_xpgflags            = 2
              invalid_jobdata         = 3
              jobname_missing         = 4
              job_notex               = 5
              job_submit_failed       = 6
              lock_failed             = 7
              program_missing         = 8
              prog_abap_and_extpg_set = 9
              OTHERS                  = 10.
    IF sy-subrc <> 0.
      e_error = true.
    ELSE.
      CALL FUNCTION 'JOB_CLOSE'
           EXPORTING
              EVENT_ID                    = IC_WWI_WORKPROCESS_EVENT
              EVENT_PARAM                 = V_EVENTPARM
              EVENT_PERIODIC              = 'X'
                jobcount                    = v_jobcount
                jobname                     = v_jobnam
                strtimmed                   = 'X'
           IMPORTING
                job_was_released            = v_flg_released
           EXCEPTIONS
                cant_start_immediate        = 1
                invalid_startdate           = 2
                jobname_missing             = 3
                job_close_failed            = 4
                job_nosteps                 = 5
                job_notex                   = 6
                lock_failed                 = 7
                OTHERS                      = 8.
      IF sy-subrc <> 0.
        e_error = true.
      ELSE.
        DO.
          CALL FUNCTION 'SHOW_JOBSTATE'
            EXPORTING
              jobcount               = v_jobcount
              jobname                = v_jobnam
           IMPORTING
        ABORTED                =
        FINISHED               =
        PRELIMINARY            =
        READY                  =
             running                =
        SCHEDULED              =
           EXCEPTIONS
             jobcount_missing       = 1
             jobname_missing        = 2
             job_notex              = 3
             OTHERS                 = 4.
          IF sy-subrc <> 0.
            e_error = true.
            MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                    WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
          ENDIF.
          IF running = space.
            EXIT.
          ENDIF.
        ENDDO.
      ENDIF.
    ENDIF.
  ENDIF.
Are u  using any ALV display while prinitng..??

Similar Messages

  • Alv report in back ground

    Hi All,
    Can we run alv report in back ground,if yes how?
    Thanks&Regards.
    Srikanth.V

    hi Ramu,
    Run in Background but make sure it is alv list, not alv Grid FM. if you are uisng alv list not problem , but if you are using alv grid then you can code like this..
    if sy-batch = ' '.
    call 'REUSE_ALV_GRID_DISPLAY'.
    else.
    call 'REUSE_ALV_LIST_DISPLAY'.
    endif.
    if you are using OO alv then write this code..
    CALL METHOD cl_gui_alv_grid=>offline
                    RECEIVING e_offline = off.
        IF off IS INITIAL.
          CREATE OBJECT g_custom_container
                 EXPORTING container_name = g_container.
        ENDIF.

  • Filter report by back ground color or by condition

    I'd like to filter my report by conditions like iif(Parameter is true, Fields.speed.value > 100 or Fields.speed.value > (speedlimit +15), nothing).  I tried using Dataset filter as following set up, but it won't return the order with speed
    over 100 or over speedlimit by 15 km/h.   
    FilterExpression: [Speed]
    >
    =iif((Parameter.Boolean.value = true, 100 or (fields.Speedlimit.value +15), 0).
    Then i filter all the cell that when speed is under the condition like
    iif(speed > 100 or speed > (speedlimit+15), "PINK", "White")
    but I don't know whether I could filter report by back ground color.
    Anyone please help me with any solution. 
    thanks.

    Thank you very much for the solution.!
    It works when i select "true' for the parameter. 
    But instead of showing all orders when "false", it shows orders under condition Fields!Speed.Value>(Fields!SpeedLimit.Value+15.
    Do you have any idea why?
    all order number is 1000
     number of orders with Field.Speed.Value > 100 is 13
     number of orders with Fields!Speed.Value>(Fields!SpeedLimit.Value+15
    is 340
     number of orders with Fields!Speed.Value>100
    or Fields!Speed.Value>(Fields!SpeedLimit.Value+15  is 353
    I'm getting 353 when "True" 340 when "False"(I do want 1000)

  • Problem when printing Alv Tree Report in back ground

    Hi,
    I am using SUBMIT ...TO SAP-SPOOL WITHOUT SPOOL DYNPRO with GET_PRINT_PARAMETERS FM.Its working fine.
    My problem is that my SUBMIT report have TREE STRUCTURE as output so when i am running my program one blank screen is coming with heading DISPLAY LOG TREE because of TREE STRUCTURE.when i click on back button then only further processing happens.
    How to avoid this TREE STRUCTURE SCREEN ???
    Is there any other way to pass your list o/p to SPOOL other than .....TO SAP-SPOOL..?
    Thanks in advance.

    in foreground when u run ALV report it holds maximum fields and displays in 1 single row, but the case is not in back ground...When any report is run in background, the default size for a line is 255 chars...So, if it more it gets splitted into 2 line item....This is how back ground job works for a report  though it is a normal report or alv report.

  • Submiting report in back ground with values

    Hello all abapers,
      I m working on one application where one module pool program will take input from user for user id and password. After verification, one back ground report will be scheduled by this program to change user pw and add some role in user's profile.
    when i schedule the prg in background i need to pass some values like user id and password entered on module pool screen...
    how do i pass it to background job when scheduling and how bg job prg will read these values..
    please advise me as its needed asap...
    thanks in advance,
    jigs.
    any helpful suggestions will be rewarded.

    Hi,
    Put the following code in user command:
    CALL FUNCTION 'JOB_OPEN'
      EXPORTING
        jobname                = 'ZSUBMIT'
    IMPORTING
       jobcount               = jbcnt
    EXCEPTIONS
       cant_create_job        = 1
       invalid_job_data       = 2
       jobname_missing        = 3
       OTHERS                 = 4
    IF sy-subrc <> 0.
    ENDIF.
    SUBMIT <program to be submitted> WITH P_user_id = user id  VIA JOB 'ZSUBMIT' NUMBER jbcnt AND RETURN.
    CALL FUNCTION 'JOB_CLOSE'
      EXPORTING
        jobcount                          = jbcnt
        jobname                           = 'ZSUBMIT'
        strtimmed                         = 'X'
    EXCEPTIONS
       CANT_START_IMMEDIATE              = 1
       INVALID_STARTDATE                 = 2
       JOBNAME_MISSING                   = 3
       JOB_CLOSE_FAILED                  = 4
       JOB_NOSTEPS                       = 5
       JOB_NOTEX                         = 6
       LOCK_FAILED                       = 7
       INVALID_TARGET                    = 8
       OTHERS                            = 9
    IF sy-subrc <> 0.
    ENDIF.
    A job called 'ZSUBMIT' will be released in background.
    Please try and award points if useful.
    Thanks and regards,
    S. Chandra Mouli.

  • Problem in scheduling job in back ground

    hi all,
    My project scenario is ,i have written a program to create WBS element.
    For 1 WBS creation ,In production it takes 20 to 30 min to create as there are many transactional bdcs.
    so i want to run that perticular code (all bdcs) in back ground.
    so i wrote another program with name 'zback_job_for_wbs_creation' and added all the required code.
    in old program,i have written some code to execute this new program in back ground . this code is below..
    FORM submit_for_job.
      TABLES:btcevtjob.
      DATA:l_jobname LIKE tbtco-jobname,
           l_jobnumber LIKE rsjobinfo-jobnumb.
      DATA: count LIKE btcevtjob-jobcount,
            jobname LIKE btcevtjob-jobname.
      DATA: job_was_released LIKE btch0000-char1.
      jobname = 'WBS_CREATION'.
      EXPORT s_scrnum TO MEMORY ID 'W_SCRNUM'.
      EXPORT iscrh TO MEMORY ID 'W_ISCRH'.
      EXPORT iscrl1 TO MEMORY ID 'W_ISCRL1'.
      EXPORT iscrl2 TO MEMORY ID 'W_ISCRL2'.
      EXPORT iscrl2b TO MEMORY ID 'W_ISCRL2B'.
      EXPORT iscrl2a  TO MEMORY ID 'W_ISCRL2A'.
      EXPORT iscrl1a  TO MEMORY ID 'W_ISCRL1A'.
      CALL FUNCTION 'JOB_OPEN'
            EXPORTING
                  jobname          = jobname
           IMPORTING
                  jobcount         = count
      SUBMIT zback_job_for_wbs_creation
      with S_SCRNNUM IN S_SCRNUM
      and return via JOB JOBNAME NUMBER COUNT TO SAP-SPOOL
      WITHOUT SPOOL  DYNPRO.
      CALL FUNCTION 'JOB_CLOSE'
          EXPORTING
         jobcount                    = count
         jobname                     = jobname
          strtimmed                   = 'X'
        IMPORTING
             job_was_released            = job_was_released
       EXCEPTIONS
            cant_start_immediate        = 1
            invalid_startdate           = 2
            jobname_missing             = 3
            job_close_failed            = 4
            job_nosteps                 = 5
            job_notex                   = 6
            lock_failed                 = 7
            OTHERS                      = 8
    here i have put break-point in my submitted program..but its not going to the program and job gets closed successfully without executing my code( Submitted Program).
    in above submit statement , if i just write submit progname and return ,then it goes to program.
    but job_close function module throws exception no 5.
    so pls help me out for this..
    i want my submitted program to be run in back ground..
    thanks.

    Hi,
    Start Job Monitor SM37 and search for your job. I think you will find it.
    Jobs are not linked to GUI frontend. So you can't debug your background job in that way.
    If you want to debug you must be tricky.
    Code a never ending loop with an exit condition which you can control by debugging.
    DATA:
    stop_for_capture.
    DO.
    IF sy-uname NE 'HABICH'. "change to your account
    EXIT.
    ENDIF.
    IF NOT stop_for_capture IS INITIAL.
    EXIT.
    ENDIF.
    ENDDO.
    When your job is running, start TA SM50 and mark relevant batch work process and
    choose by menu program -> program -> debugging.
    regards
    Walter Habich

  • Issue when submitting XML report from back end.

    Hi All,
    I have a customized XXPrinted Purchase Order Report where I am submitting it from back end as below.
    l_var := fnd_request.add_layout (template_appl_name =>'XX Custom',
    template_code =>'XX_PRINTED_PO',
    template_language =>'English',
    template_territory =>null,
    output_format =>'PDF');
    l_request_id :=fnd_request.submit_request
    (application => 'XX',
    program => 'XX_PRINTED_PO',
    When I am executing this block in PO approval workflow with the customized function XXPO_COMMUNICATION_PVT.fax_po
    It is submitting the report but output is showing in xml data (not in pdf)
    Please let me know if I am missing anything.
    Thanks in advance.

    Please post the details of the application release, database version and OS.
    Can you post the concurrent request log file here?
    Can you find any errors in the OPP log file ($APPLCSF/$APPLLOG/FNDOPP*)?
    How to Use FND_REQUEST.ADD_LAYOUT When Submitting a Concurrent Request Via a PL/SQL Procedure [ID 308658.1]
    Thanks,
    Hussein

  • Having problem submitting error report to Apple.

    I keep getting the message Submission failed.  Your report could not be submitted. Please try again later.  My email and internet both work so it's not a connection problem.  I have had this problem in the past and just never sent the report.

    Very strange. This doesn't fit my view of the world. Please, tell us if a reinstall worked.
    Otherwise one thing you could try is to open the application package, (Ctrl-click on the application and choose "See Package content".) Navigate to Contents > MacOS and double click on the icon there. That may "remind" MacOS that this is a MacOS X application.

  • Problem with export/import in back ground

    Hi Experts,
    I am having a requirement in which i am exporting an internal table to memory from one program and importing that in another program. in foreground it is working fine. But in background it is not working. Is there any work around.
    Here is sample code.
    Program1:
    types:
      begin of tab_type,
        para type string,
        dobj type string,
      end of tab_type.
    data:
      id    type c length 10 value 'TEXTS',
      text1 type string value `IKE`,
      text2 type string value `TINA`,
      line  type tab_type,
      itab  type standard table of tab_type,
        itab1  type standard table of tab_type.
    line-para = 'P1'.
    line-dobj = 'TEXT1'.
    append line to itab.
    line-para = 'P2'.
    line-dobj = 'TEXT2'.
    append line to itab.
    free memory id 'TD'.
    export itab to memory id 'TD'.
    Program2:
    types:
      begin of tab_type,
        para type string,
        dobj type string,
      end of tab_type.
    data:
      id    type c length 10 value 'TEXTS',
      text1 type string value `IKE`,
      text2 type string value `TINA`,
      line  type tab_type,
      itab  type standard table of tab_type,
        itab1  type standard table of tab_type.
    refresh itab.
    import itab from memory id 'TD'.
    free memory id 'TD'.
    clear line.
    loop at itab into line.
      write: / line-para, line-dobj.
      clear line.
    endloop.
    Thanks,
    Jyothi

    Thanks for your links Venkat.
    My problem is solved by using the SHARED BUFFER.
    Here is the code i used inthe first program
            DATA: wa_invdata(10) TYPE c VALUE 'INVDATA'.
            DATA: wa_month(10) TYPE c VALUE 'MONTH'.
            DATA: wa_process(10) TYPE c VALUE 'PROCESS'.
            EXPORT wa_month_end TO MEMORY ID 'MONTHEND'.
            EXPORT e_process = it_inv_data[]
            TO SHARED BUFFER indx(st) ID  wa_process.
            EXPORT e_month = wa_month_end
            TO SHARED BUFFER indx(st) ID  wa_month.
            EXPORT e_invdata = it_tab[]
                TO SHARED BUFFER indx(st) ID wa_invdata.
         EXPORT it_inv_data TO MEMORY ID 'PROCESS'.
            DATA: number           TYPE tbtcjob-jobcount,
                  name             TYPE tbtcjob-jobname VALUE 'CRDR_ ',
                  print_parameters TYPE pri_params.
            CONCATENATE name
                    sy-datum
                    INTO name .
    *CALL FUNCTION 'GET_PRINT_PARAMETERS'
    EXPORTING
       no_dailog              = 'X'
       archive_mode           = '3'
    IMPORTING
       out_parameters         = print_parameters
       out_archive_parameters = archi_parameters
       valid                  = valid_flag
    EXCEPTIONS
       invalid_print_params   = 2
       OTHERS                 = 4.
            CALL FUNCTION 'JOB_OPEN'
              EXPORTING
                jobname          = name
              IMPORTING
                jobcount         = number
              EXCEPTIONS
                cant_create_job  = 1
                invalid_job_data = 2
                jobname_missing  = 3
                OTHERS           = 4.
            IF sy-subrc = 0.
              print_parameters-pdest = 'locl'.
              SUBMIT zsd_crdr_monthend_back_process
                      TO SAP-SPOOL
                      SPOOL PARAMETERS print_parameters
                      WITHOUT SPOOL DYNPRO
                      VIA JOB name NUMBER number
                    AND RETURN.
              IF sy-subrc = 0.
                CALL FUNCTION 'JOB_CLOSE'
                  EXPORTING
                    jobcount             = number
                    jobname              = name
                    strtimmed            = 'X'
                  EXCEPTIONS
                    cant_start_immediate = 1
                    invalid_startdate    = 2
                    jobname_missing      = 3
                    job_close_failed     = 4
                    job_nosteps          = 5
                    job_notex            = 6
                    lock_failed          = 7
                    OTHERS               = 8.
    Second Program
    Program zsd_crdr_monthend_back_process.
      DATA: wa_invdata(10) TYPE c VALUE 'INVDATA'.
      DATA: wa_month(10) TYPE c VALUE 'MONTH'.
      DATA: wa_process(10) TYPE c VALUE 'PROCESS'.
      IMPORT e_invdata = it_tab[]
      FROM SHARED BUFFER indx(st) ID  wa_invdata.
      IF sy-subrc NE 0 OR it_tab[] IS INITIAL..
       No data found for the Month end processing
        MESSAGE s398(00)
           WITH 'No Data Found'.
        STOP.
      ELSE.
    found the data
        IMPORT e_process = it_inv_data[]
        FROM SHARED BUFFER indx(st) ID  wa_process.
        IMPORT e_month = wa_month_end
        FROM SHARED BUFFER indx(st) ID  wa_month.
    Thanks for your help.

  • Download ALV report in back ground in local directry

    thanks to all but my porblem is download the ALV report in background in local directry.
    sriram.

    HI ,
       Find the small code to download the file in background.
    n SAP ABAP you can transfer the contents of the internal table to a file. This is required when you wish to extract data from SAP tables into a flat file. This file can then be used to transfer data to another SAP or NON SAP system. This can also be used for an interfacing when you wish to transfer data on a daily or a weekly basis from R/3 to NON R/3 or SAP. The command used to create a file on the application server is as follows.
    OPEN DATASET
    Please see example code below.
    REPORT ZEX_DATATOFILE .
    *& ABAPLOVERS: Data Transfer
    Parameters to enter the path
    PARAMETERS FILENAME(128) DEFAULT '/usr/tmp/testfile.dat'
                             LOWER CASE.
    Table Declaration
    TABLES VBAK.
    Data Declaration
    DATA D_MSG_TEXT(50).
    Get data for file transfer
    DATA INT_VBAK LIKE VBAK OCCURS 100
                       WITH HEADER LINE.
    SELECT * FROM VBAK INTO TABLE INT_VBAK.
    SORT INT_VBAK BY VBELN.
    LOOP AT INT_VBAK.
      WRITE: / INT_VBAK-VBELN,
               INT_VBAK-KUNNR.
    ENDLOOP.
    Opening the File
    OPEN DATASET FILENAME FOR OUTPUT IN TEXT MODE
                          MESSAGE D_MSG_TEXT.
    IF SY-SUBRC NE 0.
      WRITE: 'File cannot be opened. Reason:', D_MSG_TEXT.
      EXIT.
    ENDIF.
    Transferring Data
    LOOP AT INT_VBAK.
      TRANSFER INT_VBAK-VBELN TO FILENAME.
    ENDLOOP.
    Closing the File
    CLOSE DATASET FILENAME.
    Regards,
    Rajesh Akarte

  • How to run a report in back ground

    how to run a report in background with out using job open, submit , close is there any other function module to run report in background.

    Hi,
               There are two ways for you to handle,
    one manually setting up the job through SM36 which is better and convinient,
    secondly through program using FM's JOB_OPEN, SUBMIT, JOB_CLOSE.
    Find below steps in doing both:
    Procedure 1:
    1. Goto Trans -> SM36
    2. Define a job with the program and variant if any
    3. Click on start condition in application tool bar
    4. In the pop-up window, click on Date/Time
    5. Below you can see a check box "Periodic Job"
    6. Next click on Period Values
    7. Select "Other Period"
    8. Now give '15' for Minutes
    9. Save the job
    Procedure 2 via Program:
    Below is a sample code for the same. Note the ZTEMP2 is the program i am scheduling with 15mins frequency.
    DATA: P_JOBCNT LIKE TBTCJOB-JOBCOUNT,
    L_RELEASE(1) TYPE c.
    CALL FUNCTION 'JOB_OPEN'
    EXPORTING
    JOBNAME = 'ZTEMP2'
    IMPORTING
    JOBCOUNT = P_JOBCNT
    EXCEPTIONS
    CANT_CREATE_JOB = 1
    INVALID_JOB_DATA = 2
    JOBNAME_MISSING = 3
    OTHERS = 4.
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    SUBMIT ZTEMP2 VIA JOB 'ZTEMP2' NUMBER P_JOBCNT
    TO SAP-SPOOL WITHOUT SPOOL DYNPRO
    WITH DESTINATION = 'HPMISPRT'
    WITH IMMEDIATELY = SPACE
    WITH KEEP_IN_SPOOL = 'X' AND RETURN.
    CALL FUNCTION 'JOB_CLOSE'
    EXPORTING
    JOBCOUNT = P_JOBCNT
    JOBNAME = 'ZTEMP2'
    STRTIMMED = 'X'
    PRDMINS = 15
    IMPORTING
    JOB_WAS_RELEASED = L_RELEASE
    EXCEPTIONS
    CANT_START_IMMEDIATE = 1
    INVALID_STARTDATE = 2
    JOBNAME_MISSING = 3
    JOB_CLOSE_FAILED = 4
    JOB_NOSTEPS = 5
    JOB_NOTEX = 6
    LOCK_FAILED = 7
    INVALID_TARGET = 8
    OTHERS = 9.
    IF SY-SUBRC <> 0.
    MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
    ENDIF.
    Hope the above helps you.
    <b>Reward points</b>
    REGARDS

  • Scheduling report in back ground after the previous report is executed

    Hi,
    There is one report which will be executed manually, once that is executed my report should be executed automatically in background.
    Pls help me in how to do this.
    Thanks,
    Lucky

    Hi,
    In the first report, try this code:
      DATA l_jobcount TYPE tbtcjob-jobcount.
      CALL FUNCTION 'JOB_OPEN'
        EXPORTING
          jobname          = 'TEST_JOB'
        IMPORTING
          jobcount         = l_jobcount
        EXCEPTIONS
          cant_create_job  = 1
          invalid_job_data = 2
          jobname_missing  = 3
          OTHERS           = 4.
      IF sy-subrc <> 0.
        CASE sy-subrc.
          WHEN 1.
            MESSAGE e054(bl)
          WHEN 2.
            MESSAGE e008(mi_badi)
          WHEN 3.
            MESSAGE e009(mi_badi)
          WHEN 4.
            MESSAGE e703(fkjo)
        ENDCASE.
      ENDIF.
      SUBMIT z_second_program
        WITH p_param1 =  'TES'
        WITH s_select_option IN s_range
        VIA JOB 'TEST_JOB' NUMBER l_jobcount
        AND RETURN.
      IF sy-subrc EQ 0.
        p_submit = true.
      ENDIF.
      CALL FUNCTION 'JOB_CLOSE'
        EXPORTING
          jobcount             = l_jobcount
          jobname              = 'TEST_JOB'
          strtimmed            = 'X'
        EXCEPTIONS
          cant_start_immediate = 1
          invalid_startdate    = 2
          jobname_missing      = 3
          job_close_failed     = 4
          job_nosteps          = 5
          job_notex            = 6
          lock_failed          = 7
          invalid_target       = 8
          OTHERS               = 9.
      IF sy-subrc <> 0.
        CASE sy-subrc.
          WHEN 1.
            MESSAGE e012(mi_badi)
          WHEN 2.
            MESSAGE e013(mi_badi)
          WHEN 3.
            MESSAGE e009(mi_badi)
          WHEN 4.
            MESSAGE e014(mi_badi)
          WHEN 5.
            MESSAGE e015(mi_badi)
          WHEN 6.
            MESSAGE e541(scpr)
          WHEN 7.
            MESSAGE e267(arch_ana)
          WHEN 8.
            MESSAGE e216(xm)
          WHEN 9.
            MESSAGE e727(fkjo)
        ENDCASE.
      ENDIF.

  • Reporting agent - Back ground scheduling

    Hello Gurus,
    I am trying to schedule the reporting agent scheduling package in Background... Is it possible to schedule it in Background when executing via Process Chain.
    Thank you

    Thanks for the Info.
    But the situation that I am facing is.. I have a remote cube and the regular cube attached to a multiprovider which is used to reconcile BW report with that of R/3 tables.
    When I execute the report in BW ... the data that is read from R3 tables ... it is under DIA process.
    the time out is set to 20 minutes. and everytime the report is executed it is saying uncaught exceptiona and when I check in the log it says time exceeded.
    Is there anyway that I can schedule the R/3 side job to a Background job (so that there would be no timeout).
    I hope I am clear..
    Please help me on this issue.

  • Avoid page break in back ground execution of report

    Hi Friends,
    Normally when we execute any report in back ground it will have page break. eg: FL3N
    But we dont see this in foreground execution of a report.
    may i know how to avoid this page break when we execute in background.
    Thanks in advance
    NNS

    Hi Badari,
    when you set the Background Job via <b>SM36</b>, you can mention the Variant. and set the time , so that the report will run for every 5 minutes with the mentioned variant. Check it.
    Regards
    Vijay

  • What is back ground processing

    what is difference between background and fore ground processing of a report. what are the various methods to execute a report in back ground.  and when we need schedule a report in back ground how shall we handle selection screen parameters.
    thanx in advance.

    Hi,
    <u><i>Background Processing</i></u>
    There are two ways for you to handle,
    one manually setting up the job through SM36 which is better and convinient,
    secondly through program using FM's JOB_OPEN, SUBMIT, JOB_CLOSE.
      Find below steps in doing both:
    Procedure 1:
      1. Goto Trans -> SM36
      2. Define a job with the program and variant if any
      3. Click on start condition in application tool bar
      4. In the pop-up window, click on Date/Time
      5. Below you can see a check box "Periodic Job"
      6. Next click on Period Values
      7. Select "Other Period"
      8. Now give '15' for Minutes
      9. Save the job
    In SM37 u can check the status of the jobs that u have assigned to background...
    Here u mention the job name or the report name to check the status of the job...
    After mentioning the job name or program name u just execute it.. ( without any name also u can execute then it gives u all the jobs set by your user name..
    the status colud be released,active,finished etc..
    Procedure 2 via Program:
    Below is a sample code for the same. Note the ZTEMP2 is the program i am scheduling with 15mins frequency.
    DATA: P_JOBCNT LIKE TBTCJOB-JOBCOUNT,
          L_RELEASE(1) TYPE c.
       CALL FUNCTION 'JOB_OPEN'
         EXPORTING
           JOBNAME                = 'ZTEMP2'
        IMPORTING
          JOBCOUNT               = P_JOBCNT
        EXCEPTIONS
          CANT_CREATE_JOB        = 1
          INVALID_JOB_DATA       = 2
          JOBNAME_MISSING        = 3
          OTHERS                 = 4.
       IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
       ENDIF.
       SUBMIT ZTEMP2 VIA JOB 'ZTEMP2' NUMBER P_JOBCNT
              TO SAP-SPOOL WITHOUT SPOOL DYNPRO
              WITH DESTINATION = 'HPMISPRT'
              WITH IMMEDIATELY = SPACE
              WITH KEEP_IN_SPOOL = 'X' AND RETURN.
       CALL FUNCTION 'JOB_CLOSE'
         EXPORTING
           JOBCOUNT                          = P_JOBCNT
           JOBNAME                           = 'ZTEMP2'
           STRTIMMED                         = 'X'
           PRDMINS                          = 15
        IMPORTING
          JOB_WAS_RELEASED                  = L_RELEASE
        EXCEPTIONS
          CANT_START_IMMEDIATE              = 1
          INVALID_STARTDATE                 = 2
          JOBNAME_MISSING                   = 3
          JOB_CLOSE_FAILED                  = 4
          JOB_NOSTEPS                       = 5
          JOB_NOTEX                         = 6
          LOCK_FAILED                       = 7
          INVALID_TARGET                    = 8
          OTHERS                            = 9.
       IF SY-SUBRC <> 0.
    * MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO
    *         WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.
       ENDIF.
    Hope the above helps you.
    Regards
    Reshma

Maybe you are looking for