Sceduling a background Job Dynamically

Hi all,
Is it possible to schedule a job by dynamically.
I have to schedule a job to run a program based on the entries.
suppose, itab contains 400 plus entries.
I have to schedule a job for every 100 entries. and once the first job is finish then only next job should run.
Please suggest me a solution.
Thanks in advance.
Eswar

In your program you can create a job with multiple steps 1 for each 100 records.
The function module used to create the job is  called  'BP_JOB_CREATE'
You within your BDC you would have a counter that ensures that only 100 records at a time where put into a session.
Each session name could be incremented by 1.
Hopefully this helps.
Regards
J

Similar Messages

  • Dynamic variants for a background job

    Hi,
    I need to set up a background job for a dynamic variant. To elaborate my selection screen has date ranges which need to change dynamically , if the job is secheduled on weekly basis the selection date range should change automatically in the variant. I got to know that the same is possible through the table TVARV. Can I know about the method of setting up the same?
    Thanks,
    Shailaja

    You can set a dynamic date to today date or some other date without using the table TVARV.
    To set the dynamic date:
    Save variant on the selection screen.
    In the vairant screen, press F4 against your field in the column "Selection Variable"
    Select D here.
    In the column Name of the variable, press F4 to have the list of the possible rules.
    Here you can select "Current date - xxx,current date + yyy" if you want to have certain period.
    When you select this system will pop up to put the values for XXX and YYY.
    Say for last 7 days, you can set the values XXX as 7 and YYY as0.
    But the best way is to change the program, if possible, and fill the select option in the intialization event.
    Regards,
    Naimesh Patel

  • Can I schedule a program as a periordic background job with dynamic viarent

    Hello experts, Can I schedule a progarm as a periodic background job run every day with dynamic condition (current day), if can,how?
    Best wishes,
    Evan

    Hi,
    You can do this to get desired results:
    Write a small new program that calls the program that you need to run daily by using submit .
    The new program can give input of current date to the called program.
    Now you can schedule the new program as a daily batch job.

  • How to set dynamic value for field Month when running background job ?

    Dear guys,
    I have a Z* report in our company, in the selection screen there is a period field (Month and Year) and this report running in background job periodically. My Question is how i can set for Month field become dynamic follow month value of date when this report executed ?
    Example :
    When Z* report running in background on 16.04.2008, Month Value will be 04 and when running on 16.05.2008, Month Value will be 05.
    Please advice.
    Regards
    Gunawan

    Dear guys,
    I have a Z* report in our company, in the selection screen there is a period field (Month and Year) and this report running in background job periodically. My Question is how i can set for Month field become dynamic follow month value of date when this report executed ?
    Example :
    When Z* report running in background on 16.04.2008, Month Value will be 04 and when running on 16.05.2008, Month Value will be 05.
    Please advice.
    Regards
    Gunawan

  • Background Job sceduled is taking a lot of time

    Dear GRC Gurus,
    I have scheduled a Background job from the Compliance Calibrator which is connecting to the DEV R3 and it is a Full Synch for the User Synchronisation.
    The DEV has got 429 GB of data and the number of Users are about 20 Users.
    The job is showing <b>"RUNNING"</b> in the Compliance Calibrator for the last 2 days.
    In ST11 Tcode we can see some reports also being generated. I am not sure where we can see the log. Please advice how we can see the log and also whether the time this job is taking is normal or not.
    Expecting for a reply soon. Thanks in anticipation.
    Best Regards
    Somnath and Chakra

    Hello Guys,
    Somnath is asking about Netweaver background jobs and not your r/3 sm37 jobs.
    in CC51 GRC create their own SM36. Remember their is not SM36 type functionality in Netweaver.
    So these are WEBDYNPRO jobs that are running.
    Well Somnath, yes it do take some time when you do Full Sync for first time. Two days is normal. But subsequent Incremental jobs will not take any time.
    Please do check that you have applied latest support pack of CC 5.1. Tell me name of CAR file you unzipped using SAPCAR command. Does it contain string SP02 or SP03.
    It should contain SP03. Also tell me on which WAS is you NW installed.

  • Error messege- Please enter a valid date in Background Job

    Hi all,
    background job which is scheduled in sm37 is giving error for dated 01.01.2009 to 30.01.2009.
    But before 31.12.2008 it was working fine
    error messege-
    This is happening in Production and developement client.
    While running the report it showing the error messege- Please enter a valid date
    One function module is used in the report for geting fiscal year from date.
    it is showing the following error messege for perticular date range- 01.01.2009 to 30.01.2009.
    GM_GET_FISCAL_YEAR
    Error
    Fiscal year variant V3 not defined or maintained for date 01.01.2009
    Thanks
    Susanta

    Hi,
    Did you put the date fields to be dynamic in your variant? i.e if in your variant you specified date range of last year, this will not work for this year and eventually give you an error message that the date is not valid...
    Dev.

  • Periodic background job scheduling

    Hello fellow SDNers,
    I have a background job which has to run periodically. So I schedule it in SM36 to run after every 10 minutes and it executes without a problem. However, I have a scenario which requires that the next execution of the job should happen only after ensuring that the first one is not active (either it should have finished execution or aborted with error).
    I need to understand the options available to handle this. Of course there is an option of writing another program to handle these jobs dynamically using JOB_OPEN, JOB_SUBMIT etc. or to create an event and trigerring it through another program and setting the job to run after this.
    Is there any other option/setting available which can save me from the programming effort (which i wish to keep as my last resort to handle this)?
    Any pointers are appreciated!!
    -Priyank

    `hi,
      u hav after event in dat select--> sap_end_of_job
    in job start conditons or esle u can check start condition in extended job selection.
    read the usage tip there..

  • How to schedule the background job using current selection screen field val

    Hello Friends,
    How to schedule the background job using current selection screen field values.
    after completion of the job the spool should be sent as a mail to SAP Inbox.
    Is there any way to create the variant dynamically by reading the current selection screen values.
    Thanks,
    Ravi

    Hi,
    To get the variant details you can use teh following FM.
    'RS_VARIANT_CONTENTS'.
    Regards,
    Ankur Parab

  • Tcode MIGO Background Job Not working

    Hi All,
    I am facing problem in TCode : MIGO for Background JOB of BDC Program with below details,
    CALL_TRANSACTION MIGO returncode: 1,001  RECORD:          0
    MIGO                 017 S
    The front end is not suitable for the transaction (see long text)
    DC                   006 S
    Control Framework: Fatal error - GUI cannot be reached
    00                   341 A
    Runtime error RAISE_EXCEPTION has occurred
    Please let me know above error what needs to be done.
    Thanks in Advance,
    Mahesh Devershetty

    I am facing the same problem while calling MIGO from RFC
    CALL_TRANSACTION MIGO returncode: 1,001 RECORD: 0
    MIGO 017 S
    The front end is not suitable for the transaction (see long text)
    DC 006 S
    Control Framework: Fatal error - GUI cannot be reached
    00 341 A
    Runtime error RAISE_EXCEPTION has occurred
    BDCMSGCOLL Returns the following :
    TCODE                   MIGO
    DYNAME               SAPLMIGO
    DYNUMB               0001
    MSGTYP               A
    MSGSPRA            E
    MSGID                  00
    MSGNR                341
    MSGV1                RAISE_EXCEPTION
    please help me as soon as possible
    giving thanks in advance
    goutam roy

  • Mail sent thru background job doesnt have all pages in attachment

    Hi Experts,
    We developed a program where the output is triggered by calling a smart form. We schedule a background job and we updated the mail address in Spool list recipent. After succesfull execution of job we checked the spool it is around 30 pages but the attachement in the mail has only 3 pages. we are not sure where the exact problem is. Can any one help us in this regard so that we can able to check and fix this issue. Thanks.

    Hi
    To check whether mail is generated you can create dynamic break-point with SAAB transaction.
    Using this transaction you create a memory area for your jobs where you can load any data value of your report..
    Probably something goes wrong with COMMIT of Mail Function module system.
    Hope to help..

  • Setting layout to a report in background job

    Hi.
    Does anybody knows how I set layouts dynamically to a report output, given that such report is scheduled to run once a day in a background job?
    It would work for me, either: through SM36 or coding JOB_OPEN / JOB_SUBMIT / JOB_CLOSE (or any other option, if available).
    My requirement is to execute every night few reports, each with their corresponding variants and layouts.
    Something like:
    RUN <report1> VARIANT <variant1> LAYOUT <layout1> JOB <job>. (it would output and xls file).
    RUN <report2> VARIANT <variant2> LAYOUT <layout1> JOB <job>. (it would output another xls file).
    RUN <report3> VARIANT <variant3> LAYOUT <layout2> JOB <job>. (it would output a 3rd xls file).
    How should I do to inform variant and layout parameters?
    Thank you.
    Rafael.

    I think I didn't make myself clear in my explanation. Sorry about that.
    My question is, I can create a new field in selection-screen specifically to layout and it would work. However, as I'm running it in background, the ALV will not be shown and the output file must be the export of the ALV with the layout (if in XLS, it'd be even better, but in .CSV would work as well). I just don't think it would work with a .TXT output, because there's no way to reflect the layout in a .TXT file.
    Is there any way of having the ALV inside the output file (saved in the server, in background processing)?
    Thank you so much!
    Edited by: rvsilvax on Nov 30, 2011 3:45 PM

  • Report layout - ME2N - Automatic background job

    HI all
    We are using the above report for Pending PO-RElease ie., dynamic selection - release indicator "B"  thru automatic background programme schedueld thru SM36 (after setting the variant) for the relevant/concerned users.
    The issue is, the report layout be default standard sap layout is taking, actually i have saved layout as PO no & date, but always, whenever background job is run, default sap report is taken in HTML.
    request kindly help how i can ensure my our report layout for backgrounds jobs thru ME2N or is there any other report which can give the pending PO-Release report for my requirement.
    thanks in advance
    regards
    srihari

    I am doing same as suggested by you for all other reports, but i am not successful with ME2N, because after having your own default layout, but for background it is default taking sap report. even i have tried to delete the sap - std report format but not allowed.
    if any one knows how to change the sap-default std report layout then also it's okay for us, as default report as 15 columns whereas we need only max 5 columns in report layout
    thanx in advance
    regards
    srihari

  • Schedule Module program in Background with Dynamic Input values ?

    Hi,
    I am trying a schedule a Standard Transaction which has Month,year and other Check boxes (By default they are Empty) .I need to schedule it monthly and Input must change dynamically when I run in background each month..
    How do we do this?
    Regards
    Vara
    Message was edited by: Vara K

    You can not directly schedule a module pool program in background job.  These are usually reports.   What you can do is create a custom report program with your parameters on a selection screen.  In this program you can do a BDC over the standard transaction filling the parameters from the selection screen of the custom program.  This custom program can also have a selection screen variant which uses selection variables that will change dynamically.  Then you can schedule the custom report program via SM36.
    Regards,
    Rich HEilman

  • Background Jobs are failing

    Hi Gurus,
    Below are the jobs which are being failed in our solution manager system since two weeks with error " Logon of user 'DDAWES' in cleint 100 failed.  Found that user got locked due to some auditing reasons and i had changed the background jobs  to run with another user however jobs are failing with same errror.
    Jobs List:
    SM:ACCELERATE DOC USAGE
    SM:CSA SESSION REFRESH
    SM:DYNAMIC TABU UPDATE
    SM:EXEC SERVICES
    SM:REFRESH ENTRYSCREEN
    SM:RNOTIFUPDATE01
    SM:SESSIONS RESET
    Unsure about this case why the jobs were failing though we have changed the user.
    Any sugegssions would be much appriciable
    Thanks & Regards,
    Vinod

    Both users are having same authorizations and both are dailog users only. It looks weird when i changed the user in job step for released jobs, it got changed and updated the job step with new use at that moment. However the jobs are faling and when i go through the job logs there I could see that OLd user name in job step.
    Changed the released  jobs many times to run with another user, however the jobs are failing with error " Logon of user DDAWES in client 100 failed when starting a step".
    Please note the jobs were running fine before the user locked out due to auditing. Also please let me know how do i check the E2E changes ? in SDM ? is ther any transaction code that i can check?
    Please suggest...
    Thanks & Regards,
    Vinod
    Edited by: vinod kumar on Jul 6, 2009 5:34 PM

  • Different Subroutines in Background jobs and Dialog jobs

    Hi guys,
    I want to execute some subroutines when the program is running  using a background  job  , and some other subroutines completely different when the user use dialog job ( program -> execute in background ) . I know that sy-batch  = 'X'  in both cases  , but, there is something else to identify them ? , any ideas .
    thank you .

    It will be - he meant that they start the background job from SE38/SA38 not run it online.
    SY-SLSET is a starter point for checking the variant used - dynamic variants are used when you don't pick one from the list.  However, this would not help if the user picked a variant and then scheduled the job dynamically.  Another option is to use function GET_JOB_RUNTIME_INFO in your program.  Assuming your scheduled jobs are named differently, you can check for the condition by checking the name of the running job.  Dynamically created jobs will have the program name as the job name.

Maybe you are looking for