Reg Background Jobs

Hi,
  I have scheduled a background job which have three steps. The first step is a zprogram and the second is standard program to generate sessions and the last step is to execute that session in background.
The problem i m getting, when there are no records in the first step, it is going to the second step and getting cancelled.
How can I come out of the other two steps in the job, when there are no records.
Regards,
Ramesh.

Hi Jelena,
The best option is to create 2 background jobs instead of 3.
The first job as the Z program,write a Submit to the SAP standard  program from the first one only when there are records in the first one and create the 3rd as the second background job.
I hope I have tried to answer to the best of my knowledge.
In case you have any further queries,please let me know.
Regards,
Puneet Jhari.

Similar Messages

  • Reg Background job execution

    Hi gurus,
    I have a doubt in back ground job processing...We have a job which runs for very long time (archiving job). I want that job to run from Sunday morning to evening 6PM again I need to run the same job next sunday morning to evening continuing from previous week stop point.
    My question , there is a option in SM37 to STOP the job. If I stop the job and then resume back the same job, will it continue from the point where it stopped?
    Is there any way to execute the background job like above scenario. I know it can be done by 3rd party tool, but I want to do the same from R/3
    Vinodh

    Hi Vinodh,
    In later versions of SAP (from Enterprise version if iam not wrong), you can interrupt the archive job and continue later. This is not the feature of background processing, but the archiving job itself.
    Interruption is possible on basis of duration of the job and size of archive file. See the following link which details the mentioned feature; go to The Archive Development Kit and see the topic Interrupting and Continuing Archive Sessions:
    http://help.sap.com/saphelp_47x200/helpdata/en/6d/56a06a463411d189000000e8323d3a/frameset.htm
    Hope this helps to work towards the solution of your problem.
    Regards,
    Naveen

  • Reg : Background job

    Hi Guru's
    I am sending IDOC from R/3 System to APO System.when idoc reached APO system.its triggers immediately and creating one file in application server(APO).sometimes this process makes more than 10 to 15 hours so user dont know whether is executing or failed. so i gave one soltion to user that is creating background job while idoc is executing when its idoc is processed then the background job also shows that finished..i dont know how to write this background job code in IDOC function module and also i dont know its possible in IDOC. i dont have knowledge in IDOC..Please helpme on this issue.
    anybody helpme on this issue.????
    Regards
    P.Senthil Kumar

    Hi,
    You have not to write Back Ground Code in FM of IDOC.
    To Process Idoc in Back Ground do following Step
    Go to T-CODE We20
    Select Partner
    Double Click on any IDOC Message type in Outbound Parameter like INVOIC
    In Outbound Options Tab, at Output Mode select Collect Idoc Radio Button.
    For Inbound parameterDouble Click on any Message type.
    Select Trigger by BackGround Program Radio Button
    Please use T-code SM36 to schedule program which process Idoc.
    The Program used is,
    RSEOUT00 : For Processing 30 Status IDocs For outbound Idoc
    RBDAPP01 : For Processing 64 Status IDocs For Inbound Idocs
    T-code BD87
    To Refer more about IDOC,
    https://wiki.sdn.sap.com/wiki/display/ABAP/ALE%2CIDOC
    https://wiki.sdn.sap.com/wiki/display/ABAP/ALE+IDOCS
    Thanks & Regards,
    ShreeMohan
    Thanks & Regards,
    ShreeMohan

  • Reg Background Job Notifications

    Hi,
    I wanna add a user email id for background job failure notifications. How do I do that.
    Thanks
    NM

    Hi,
    You can create a Custom program, which will pick the Jobs which have failed and then send the information through EMAIL.
    Check the following link.
    http://jplamontre.free.fr/SAP/Send%20background%20job%20failure%20alerts%20by%20email.htm
    Also go through this link. It might be useful
    https://www.sdn.sap.com/irj/sdn/go/portal/prtroot/docs/library/uuid/97d2e8b3-0b01-0010-b787-b8ce558a51c2
    Regards,
    Aj
    Reward points if useful
    Message was edited by:
            Abhishek Jolly

  • Reg:Background jobs are failing with out logs

    Hi Team,
    When i ran sm65 transaction in production i got the output.
      Test: Database table consistency test
         ==>  Inconsistent step no. for following job(s):
             ACS_SAP_HR                      14525701
             ACS_SAP_HR                      14525702
             ACS_SAP_HR                      14525801
             AUTO_SESSION_MANAGER            22091204
             AUTO_SESSION_MANAGER            22091301
             AUTO_SESSION_MANAGER            22132501
             EU_PUT                          19060603
             EU_REORG                        18180604
             OPEN_ENROLLMENT_SEND_EMAIL      15145305
             OPEN_ENROLLMENT_SEND_EMAIL      18301801
             RPTIME00                        22000822
             RSUVM008                        14330102
             SEND_INET_EMAIL                 08082001
    Can you please let me know how to proceed further.
    Thanks & Regards,
    Deve

    check this might help you
    http://mailman.mit.edu/pipermail/sap-wug/2005-July/018391.html
    Note 581692 - Apparently inconsistent job data - incorrect stepcount
    Note 1272015 - Jobs with empty job names or job count
    Note 37104 - Error analysis: Background processing system
    Edited by: Bhudev on May 22, 2009 6:22 AM

  • Reg : background job error

    hi,
    i have scheduled a job  in batch mode.
    the job is cancelled and got a error message saying that
    "Job cancelled after system exception ERROR_MESSAGE ".
    Can you please tell me what would be the problem??
    regards
    ravi

    hi actually my task is to find out why this error has occured.
    when i seee the prgs related to this job , i got two and in those no error msgs related to the error which i am getting is there.
    just they have given the screeen shot and said it is a prod issue. i dont know whether i can debug in production for this job,,
    can i debug the job as u said like typing in command line as jdbg??????????
    its an urgent one .. plz help me out

  • Reg: - Background job scheduling

    Hi experts,
    I have to develop a report which will execute in background mode every night.
    Based on some calculations i have to write some summary like if i am deleting some records from Z tables then i have to write 'Records deleted from Z table' with timestamp value.
    As per my understanding, I can use simple write statement & it will be written in spool. Next day user can see the spool with summary. I am not sure abt this approach.
    Please suggest me.
    with regards,
    Sachin

    hi
    1. The answer to your question is :
    the FM
    GET_JOB_RUNTIME_INFO
    2. Use this FM inside the code
    of your report.
    3. It will give you various details like.
    EVENTID
    EVENTPARM
    EXTERNAL_PROGRAM_ACTIVE
    JOBCOUNT
    JOBNAME
    STEPCOUNT
    regards
    ravish
    <b>plz reward points if helpful</b>

  • Reg: Error in Mail sending through background job in SCOT

    Hello experts,
    I am trying to schedule a background job through SCOT so as to send the mails present in SOST.
    The job is running but it is giving error as "Invalid status  for recipient" in SOST.
    But when I am sending it directly from SOST it is delivered without any errors. The email address is maintained correctly and SMTP settings are also correct as while sending it directly from SOST it reaches the required recipient without any error.
    This error is observed only through background job. I am using program RSCONN01 with variant SAP&CONNECTINT in background job.
    Kindly suggest why I am getting the error "Invalid status  for recipient" in background job.
    Thanks & Regards
    Meraz
    +91 8894522860

    I am getting the exact same issue.
    were you able to fix this in the last 3 weeks?
    thanks.

  • Reg Super user for schedule background Jobs

    Hi Experts,
    I have created new user copied from DDIC with the same authorization. This is for scheduling Background Jobs. Now all the standard background Jobs are running fine. After scheduling the Jobs I have changed to system user. Now for audit purpose I need SAP note to do same. Please help me to get the sap note for the same. Please respond ASAP. treat this is as high priority.
    Thanks & Regards,
    Haseem.

    HI,
    It is not necessary for user having SAP_ALL authorization under which background job is running.
    Define specific users to use for background processing. Define them as system users (non-dialog) and give them only the necessary authorizations that are needed for the executed programs
    check  http://help.sap.com/saphelp_nw04/helpdata/en/db/f6f3393bef4604e10000000a11402f/frameset.htm
    also check Note 101146 - Batch: authorization object S_BTCH_JOB, S_BTCH_NAM
    regards,
    kaushal

  • Reg: File Extraction from SAP Queries via background job

    Hi ,
    Is it possible to Extract a file to the presentation Server by running the ABAP Query's through SQ01 as a back ground job to generate a file automatically without running it manually.
    I have tried recording the query's thru SQ01 with the File store Option to download it to Excel on the Presentation server.I have used CAll Transaction for SQ01 in the Zprg and submitted that Query to be able to download that Query in the mentioned path .The Zprg was executed via Background job.The file is extracted to the presentation server when the Zprg was executed via Foreground,but its not getting Downloaded to Excel Via Back ground job.
    Please provide me the solution.
    Thanks in advance,
    Prem

    Hi
    u cannot get file in presentation server.. in background..
    if you are scheduling any background jobs it should be out of any gui interface.. like gui_dowload , gui_upload// ur need to replace then with cl_gui_fronend_services Class
    or u have a option of writing file to application server in background using open dataset syntax.

  • Userexit or BADI for program *RMMRP000* for background job

    Hi,
    We are scheduling background job for MRP through SM36 using program  RMMRP000 or Through Transaction MDBT (MDBT is calling program RMMRP000) which creates PR (through background job).
    I want to default one field in PR (PO Price field in valuation tab in PR default to gross) using any userexit or BADI.
    Can any body suggest me userexit or BADI for program RMMRP000 for background job
    Regards.

    Hi,
    1. The below are the List of  Userexit for this MDBT t.CODE.
    2. But i dont see any one helping to resolve your issue.
    3. May be you should lookg at the Userexit for me21n or relevant Purhcase requisition creation transaction.
    reg
    dsk

  • Problems creating background job for program (job open, submit and close)

    Hi gurus,
    im trying to start a background job using the FM BP_START_DATE_EDITOR to show the start date to the job or if it's imediate. this FM it's working fine, after call it im opening a job, submiting it and call the job close FM and the job close FM creates me the job.
    The problem it's when i go to the sm37 to see the job status the job has been canceled, and the job log says that i have to give a start date to the job.
    What i dont understand it's either the job is imediate or i choose a date to start the job always gives me this error...
    Below goes my code,
    any ideas will be rewarded
      CLEAR: stdt_modify_type, stdt_output.
      CALL FUNCTION 'BP_START_DATE_EDITOR'
           EXPORTING
                stdt_dialog                    = 'Y'
                stdt_input                     = stdt_input
                stdt_opcode                    = 14
           IMPORTING
                stdt_modify_type               = stdt_modify_type
                stdt_output                    = stdt_output
           EXCEPTIONS
                fcal_id_not_defined            = 1
                incomplete_last_startdate      = 2
                incomplete_startdate           = 3
                invalid_dialog_type            = 4
                invalid_eventid                = 5
                invalid_opcode                 = 6
                invalid_opmode_name            = 7
                invalid_periodbehaviour        = 8
                invalid_predecessor_jobname    = 9
                last_startdate_in_the_past     = 10
                no_period_data_given           = 11
                no_startdate_given             = 12
                period_and_predjob_no_way      = 13
                period_too_small_for_limit     = 14
                predecessor_jobname_not_unique = 15
                startdate_interval_too_large   = 16
                startdate_in_the_past          = 17
                startdate_is_a_holiday         = 18
                startdate_out_of_fcal_range    = 19
                stdt_before_holiday_in_past    = 20
                unknown_fcal_error_occured     = 21
                no_workday_nr_given            = 22
                invalid_workday_countdir       = 23
                invalid_workday_nr             = 24
                notbefore_stdt_missing         = 25
                workday_starttime_missing      = 26
                no_eventid_given               = 27
                OTHERS                         = 28.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE sy-msgty NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        MOVE 'X' TO gv_flag.
      ENDIF.
      DATA jobname LIKE tbtcjob-jobname.
      DATA jobcount LIKE tbtcjob-jobcount.
      DATA job_release LIKE  btch0000-char1.
      DATA job_imediate TYPE c.
      CLEAR: jobname, jobcount, job_release.
      CONCATENATE 'MAPAEXEC' sy-uname sy-datum
                   INTO jobname SEPARATED BY space.
      CALL FUNCTION 'JOB_OPEN'
           EXPORTING
                jobname          = jobname
           IMPORTING
                jobcount         = jobcount
           EXCEPTIONS
                cant_create_job  = 1
                invalid_job_data = 2
                jobname_missing  = 3
                OTHERS           = 4.
      IF sy-subrc <> 0.
        MESSAGE i003(zmapas).
        EXIT.
      ENDIF.
      SUBMIT z_mapa_execucao_orcamental
             VIA JOB jobname NUMBER jobcount
             WITH ano EQ ano
             WITH so_perio IN so_perio
             WITH so_date IN so_date
             WITH so_org EQ so_org
             WITH so_num IN so_num
             AND RETURN.
      IF stdt_output-startdttyp EQ 'I'.
        CLEAR job_imediate.
        job_imediate = 'X'.
      ENDIF.
      CALL FUNCTION 'JOB_CLOSE'
           EXPORTING
                calendar_id                 = stdt_output-calendarid
                event_id                    = stdt_output-eventid
                event_param                 = stdt_output-eventparm
                event_periodic              = stdt_output-periodic  "?
                jobcount                    = jobcount
                jobname                     = jobname
                laststrtdt                  = stdt_output-laststrtdt
                laststrttm                  = stdt_output-laststrttm
                prddays                     = stdt_output-prddays  "??
                prdhours                    = stdt_output-prdhours  "?
                prdmins                     = stdt_output-prdmins  "??
                prdmonths                   = stdt_output-prdmonths
                prdweeks                    = stdt_output-prdweeks  "?
                predjob_checkstat           = stdt_output-checkstat
                pred_jobcount               = stdt_output-predjobcnt
                pred_jobname                = stdt_output-predjob
                sdlstrtdt                   = stdt_output-sdlstrtdt
                sdlstrttm                   = stdt_output-sdlstrttm
                strtimmed                   = job_imediate
                targetsystem                = stdt_output-instname
                start_on_workday_not_before = stdt_output-notbefore
                start_on_workday_nr         = stdt_output-wdayno
                workday_count_direction     = stdt_output-wdaycdir
           IMPORTING
                job_was_released            = job_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
                OTHERS                      = 8.
      IF sy-subrc <> 0.
        MESSAGE i003(zmapas).
        EXIT.
      ELSE.
        MESSAGE i004(zmapas) WITH jobname.
      ENDIF.
    Thanks in advance,
    Best Regards
    João Martins

    Hello João.
    In debug mode, check the value of variables you passed to parameters sdlstrtdt and sdlstrttm.
    As aditional info, I usually achieve your goal without FM BP_START_DATE_EDITOR.
    Check this code:
    CALL FUNCTION 'JOB_OPEN'
          EXPORTING
               jobname          = w_jobname
          IMPORTING
               jobcount         = w_jobcount
          EXCEPTIONS
               cant_create_job  = 1
               invalid_job_data = 2
               jobname_missing  = 3
               OTHERS           = 4.
    CHECK sy-subrc = 0.
    CLEAR seltab_wa.
    MOVE: t_jobs-param TO seltab_wa-selname,
    t_processar-line+34 TO seltab_wa-low.
    APPEND seltab_wa TO seltab.
    seltab_wa-selname = 'P_LOJA'.
    seltab_wa-low = t_processar-ficheiro+7(4).
    APPEND seltab_wa TO seltab.
    *** Submete o programa para o JOB
    SUBMIT (t_jobs-repid)
      WITH  SELECTION-TABLE seltab
      USER sy-uname
       VIA JOB w_jobname NUMBER w_jobcount
       AND RETURN.
    *** Encerra o JOB
      l_hora = sy-uzeit.
      ADD 60 TO l_hora.
    CALL FUNCTION 'JOB_CLOSE'
       EXPORTING
          jobcount           = w_jobcount
          jobname           = w_jobname
          sdlstrtdt            = sy-datum
          sdlstrttm           = l_hora
          targetserver       = w_servidor
       IMPORTING
          job_was_released     = l_liberado
       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.
    Regards.
    Valter Oliveira.

  • Scheduling one background job inside another

    Hi All,
    Is it possible to Scheduling one background job inside another.? i.e In my Z program I am calling job_open, job_submit, job_close and to execute one standard report in background. And after that I am executing my Z program itself  from SE38 as Program->Execute->Background->Execute Immediately. Is this logically correct? I am asking this because I am not getting the desired result
    Thanks & Regards,
    Neethu.

    HI,
    Check the job steps in SM36.
    First schedule the Standard job and in the job steps schedule the z report.
    Schedule job in chain

  • Background Job pass value

    Hi, I am calling a Background job in my program. I am using JOB_OPEN, JOB_SUBMIT and JOB_CLOSE FM to start a job. My need is to pass a value to the job program(job program doesnt have any selection screen values). Is their any way without creating variants each time to pass value to it.
    Please advice.....

    Hello,
    You can first use  JOB_OPEN which returns job number. Then build ranges or parameters to use SUBMIT to call the program.
    Eg: SUBMIT RM06BB20 AND RETURN
          WITH S_EKGRP IN R_EKGRP
          WITH S_EKORG IN R_EKORG
          WITH S_FLIEF IN R_FLIEF
          WITH S_KONNR IN R_KONNR
          USER sy-uname VIA JOB w_jobname
          NUMBER w_job_number.
    Now use JOB_CLOSE.
    Thanks,
    Venu

  • How can i get Background Jobs list which is made me?

    I created background job using JOB_OPEN and SUBMIT and JOB_CLOSE.
    I need to Background Job list which is made me..
    Do u know any function or logic?
    plz~

    [BP_JOBVARIANT_OVERVIEW|http://help.sap.com/saphelp_45b/helpdata/en/fa/096ccb543b11d1898e0000e8322d00/frameset.htm]
    BP_JOBLOG_READ

Maybe you are looking for

  • Passing Parameters to Discoverer report from ORacle Forms

    Hi All, Can I pass a value to a parameter defined in the discoverer page from a D2k form? I want to call a discovere page from fmb while passing a parameter. This is extremely urgent for me. Pl help . Thank you and Regards, Vaibhav M. Shah.

  • Apple Refuses to Fix my Ipod!

    I just sent my 60gb video ipod in because the screen no longer works. There are absolutely no cracks, dents, or visible scratches on my ipod. And yet! Apple said their diagnosis indicates that the "crack" on my screen has resulted from an external ca

  • Why is their customer service so poor?

    On June 13th I went into a Verizon store in Chicago, one that I have been to many times. The wait is always tremendous but I try to let that go since it's a downtown, loop located Chicago store. I'm adding a line to my plan. The salesperson took it u

  • Can you preview before publishing?

    Is there a way to preview your page before publishing? I cant see the browser background color in the layout in iWeb.

  • Overwrite Maintenance order address in IW32

    Hi expert, I've got requirement to replace some value in Maintenance order address (for example: Name and Postal Code) that was changed by user and need change it back to previous value. I tried to use EXIT_SAPLCOIH_009 but didn't get the details in