Executing a Batch Job on Demand

Hi,
I need to execute a batch job which accepts data from flat files and then stage, validate, standardize and match the data and then produce an XML output for further processing. The volume of data will not be large as the flat files are produced via a GUI.
What would be the best way to enable this job to be called as required by the users ?
I can think of possibly
1) a very big real time job
2) a real time job containing a command line to execute the job
3) embedding the command line within the GUI (not sure if this is possible / practical)
Any pros and cons of these ideas or any other better ways much appreciated.
Thanks,
Eric.

Hi Eric,
This does not require a real time job, just a normal batch job called frequently on-demand.
You could do this via:
1. Command Line in bat script or GUI (requires executables on client)
2. Call your Job via a Web Service (within GUI or app)
Option 1 (calling the Job Launcher) will require the executables to be installed on each client machine that calls the Job, whereas option 2 will eliminate any need for executables.
Richard

Similar Messages

  • Setting default date range in selection screen when executing as batch job.

    Hi Guys,
    I have one report to be scheduled as weekly batch job and one of the selection screen field is date range. If i set this report to run today then the date range will be from one week back date(Lower value) to today date(Higher value). When it runs for next week(Already scheduled as weekly batch job) the date range should be like this
    Lower value = today date
    higher value= next week run date.
    How can i achieve this functionality. Is it possible through Dynamic variant concept?. Rest of the selection screen fields have some default values and should not change.
    <REMOVED BY MODERATOR>
    Thanks in advance,
    Vinod.
    Edited by: Alvaro Tejada Galindo on Feb 22, 2008 3:52 PM

    Hi Vinod,
    Would suggest you to this.
    Create two parameters : p_start_date and p_end_date of type sy-datum on your selection screen , instead of a range.
    Now goto create a variant from SE38 for the report.
    While creating the variant, mark the "Selection Variable" checkbox for the two parameters and click on "Selection Variables".
    Select the option "D: Dynamic date calculation" for both the date fields.
    For p_start_date - select the option "Current Date"
    For p_end_date  - select the option "Current date +/- ??? days" and put 7 in the pop up.
    Hence what you have done now is, set up a dynamic variant, where p_start_date will have sy-datum and p_end_date will have sy-datum + 7, everytime the job runs.
    Now, in the program, first step after START-OF-SELECTION code the following:
    RANGES: r_date FOR sy-datum.
    start-of-selection.
    refresh r_date.
    r_date-sign = 'I'. r_date-option = 'BT'.
    r_date-low = p_start_date. r_date-high = p_end_date.
    append r_date.
    Hence this way, you would have built your range and use it as needed.
    Cheers,
    Aditya

  • Can U set breakpoint within a batch job and look at variables?

    Hello friends,
    I am trying to solve a problem that occurs within a program / transaction which can only be executed in background. The transaction in question is FPCOPARA and apparently this program cannot be executed in foreground.
    If I understand well, we cannot set breakpoints within a background job and as a result we cannot inspect variable etc. during job execution. So the question is how to achieve the same goal within a batch job? How did you do it? As this is a standard SAP transacrtion, no program modification can be applied.
    Your help is greatly appreciated.

    Hi......
    After u have executed ur batch job..
    go to sm37 >>select ur job using checkbox>>enter 'JDBG' in transaction box and press enter
    now debugger will start ..initial it will go through system code..after after a while the debugger will reach to your code and den you can debug the remaining report....
    all the best
    regards
    vivek

  • Smartform Printing through Batch Job

    Hi
    Please help in the following issue :
    We have a report thourgh which say 10 pages needs to be printed.
    On eachpage we have page numbers like 1 of 10, 2 of 10 etc. and on the last page 10 of 10 will be printed.
    when the report is executed in foreground, the rints are perfect s expected. But when the same report is executed through Batch Job, the pages are being printed as 1 of &&, 2 of && etc, when it come to last page the print is 10 of 10.
    So, thr Batch job the last page of the print is OK, except all other pages, the issue is only printing this page nos.
    Please advise.
    Regards
    Shankar

    hi ,
    make sure that u declared that page no printing window as final window.try it.
    Regards,
    karthikeyan k s,

  • Skipping transaction for batch job on streams

    We need to run a batch job on streams soruce side. I would like to skip this transaction from streams to capture & apply.
    Then run the batch jobs on source & target seperately. How to do it?

    There are plenty of valid reasons to execute a batch job independently of replication, not the least of which is that it's a recommended best practice from Oracle.
    Minimize the Performance Impact of Batch Processing
    For best performance, the commit point for a batch processing job should be kept low. Also, if a large batch processing job must be run at a source database, then consider running it at each Streams replication database independently. If this technique is used, then make sure the changes resulting from the batch processing job are not replicated. To accomplish this, run the DBMS_STREAMS.SET_TAG procedure in the session that runs the batch processing job, and set the session tag to a value that will not be captured by a capture process.
    Unless you have made explicit changes to the tag used in your streams rules they are all configured to only replicate if the streams tag is null. If you set this to not-null in a session, changes within that session will not be replicated. For example
    exec dbms_streams.set_tag(hextoraw('99'));
    You can turn it back on in that session (if needed) with
    exec dbms_streams.set_tag(null);
    So, if you set the tag in your batch job you can execute it independently of replication.

  • Batch file not executing in BODS Job

    Hi friends,
    I have created a batch file to create a text file in a directory. I ran it manually and it worked fine i.e a txt file was created, However when I used the batch file in script in BODS job, It's not being executed.
    The script being used is as follows ( I have tried both, Both worked manually but not in Job, the job ran successfully without desired output )
    print(exec('C:\xxx\testdir.bat ','',0));
    exec('C:\xxx\testdir.bat ','',8);
    testdir.bat has the below txt code
    cd C:\xxx\yyy dir *.xml /b > dir.txt
    Thanks and Regards
    Anil

    What have you changed between
    However when I used the batch file in script in BODS job, It's not being executed
    and
    The Job was successfully executed but  an empty dir.txt was created with no files.

  • How to set a  Executable ABAP  Program to run as a Background Batch Job

    Hi
    Currently  I had a Executable ABAP  Program which when executed prompts for user to enter selection once entered and executed it will delete user entered selections from a Table.
    Now my requirment is to enhance that program to run it as a BACKGROUND BATCH JOB so that there will be an entry in SM37 when the program is executed
    How can i achieve this

    Hi,
    Please refer this link .
    It has the steps.
    http://sapient.wordpress.com/2007/06/19/how-do-you-set-up-background-jobs-in-sap/
    Regards,
    SuryaD.

  • How should i execute file transfer via batch job scheduling

    Hi guys,
        i want to call unix transfer script via batch job scheduling. Executing the system commands witin ABAP is as below:
             DATA: BEGIN OF ITAB occurs 0,
                         LINE(200),
                        END OF ITAB.
            UNIXCOMM = '/usr/sap/trans/data/*******'
            CALL 'SYSTEM' ID 'COMMAND' FIELD UNIXCOMM
                    ID 'TAB'     FIELD itab-sys.
    Now i plan to assign application server ('Exec Target') to it and let it implement in the background.
      Should i do it via batch job?
    Any info is appreciated very much.

    Instead of using
    CALL 'SYSTEM' u can use FM..
    SXPG_COMMAND_EXECUTE  .. in which u have to pass a command name which u can create or get from SM49...
    In CALL 'SYSTEM' .. u can not catch exceptions.. but in FM given above u can check
    SY-SUBRC, STATUS and EXITCODE  for successful  command execution..
    for successful command execution..
    sy-subrc = 0
    STATUS = 'O'  " Capital O
    exitcode = 0
    For batch scheduling, you can use this FM in a report  with one parameter for additional parameter which u need to pass to this FM  and create a JOB for that report and schedule it..
    I've used it and  find it useful even for batch scheduling..
    Reward if useful
    Regards
    Prax

  • Creating a Batch Job for Executing Later

    Hi Experts!
    I was wondering if there was a way to create a batch job, but to have it executed at a later time, since we do not have an exact date and time we need these jobs executed.  My goal is to create 12 batch jobs (1 for each month), but have them excuted, when I need them too, when I choose it.  Is this even possible?.  I tried looking through SM36/SM37, but could not find anything on it.  Please advise and thanks in advance!
    WC

    Hi Will,
    The standard job scheduler will not do this (SM36/7).  You do not mention what release you are using, but SAP Central Job Scheduling with Redwood does provide the ability to create jobs with boolean conditions like you describe (plus much, much more).  See the Service Marketplace http://service.sap.com/job-scheduling or the SDN page https://www.sdn.sap.com/irj/sdn/docs?rid=/webcontent/uuid/abb91c2a-0b01-0010-6ca6-9f0f62268454. [original link is broken]
    Best Regards,
    Matt

  • Executing the batch file from SQL Server Agent job

    Hi - I have a simple batch file (.bat) which connects the SFTP server and drop the files to location machine.  When I run the .bat file manually its working fine but when I schedule it in SQL Agent its keep on running and never shows success message. 
    Could you please tell me how can i resolve it.  Its very urgent for me.
    thanks

    If you trust this host, enter "y" to add the key to
    PuTTY's cache and carry on connecting.
    If you want to carry on connecting just once, without
    adding the key to the cache, enter "n".
    If you do not trust this host, press Return to abandon the
    connection.
    Store key in cache? (y/n) Remote working directory is /
    When you connect via putty you get prompted to accept a key in interactive mode. At this point your batch file is waiting for someone to type in y or n.  
    Try running putty in batch mode to get around this.
    http://the.earth.li/~sgtatham/putty/0.52/htmldoc/Chapter6.html#6.1.8
    6.1.8 -batch: avoid interactive prompts
    If you use the -batch option, PSFTP will never give an interactive prompt while establishing the connection. If the server's host key
    is invalid, for example (see section 2.2), then the connection will simply be abandoned instead of asking you what to do next.
    This may help PSFTP's behaviour when it is used in automated scripts: using -batch, if something goes wrong at connection time, the batch
    job will fail rather than hang.

  • Waiting for a batch job to finish before executing a process chain

    hello guys,
    do you  have any good readup that allow me to configure a process chain to only start extraction once the batch job to fill up a table has been completed in ECC? thanks in advance.

    Hi,
    You can refer the below links :
    R3 job completion trigger a process chain to run on BW
    Triggering a Process Chain From R/3 pgm
    R/3 Jobs Triggering  BW job
    Thanks.

  • Batch job not creating purchase requisitions

    I have a batch job that runs every day at 5 pm.  The point of this job is to run the MRP and create purchase requisitions for materials that have more demand than current supply.
    Programs ran within the jobu2026
    RWPOB001
    RVV50R10C
    RMMRP000
    My problem...
    Purchase Requisitions are not being created for random materials after the batch job has been ran.  When the MRP is run by itself (MD01), ALL materials will have purchase requisitions created for them without fail.  There is no order to it, and no one has kept track of any material numbers that have not had purchase requisitions created, so I cannot check the configuration.
    How I would like to investigateu2026
    1 u2013 Obtain a list of ALL purchase requisitions created in the timeframe AFTER the batch job has been ran
    2 u2013 Export this list into Excel
    3 u2013 Run the MRP manually to create purchase requisitions for ALL materials
    4 u2013 Obtain new list of ALL purchase requisitions created in the timeframe AFTER the MRP was manually ran
    5 u2013 Export this list into Excel
    6 u2013 Compare both lists; remove duplicates, display materials and requisitions that were created AFTER the batch job missed them.
    How would I go about getting a full list of purchase requisitions that have been created within the time frame the batch job has been ran, then export them into excel?  I understand that ME5A is the standard transaction for displaying lists of purchase requisitions, but how would I go about pulling all purchase reqs CREATED within a certain time period?
    Please, include specific SAP transactions and details in your answers.
    Also, if anyone has any good advice regarding how to get to the bottom of this specific issue, Iu2019m open to suggestions.  All good suggestions will be rewarded promptly.

    Cameron Lawrence Dunbar wrote:
    >
    > You mention that RMMRP000 should be ran before requirements planning.  Is it possible that our positioning of the program at the end of the job is causing these issues?  Or is it most likely the varient/parameters of one of these programs?
    >
    > Also, how can I display a list of purchase requisitions CREATED over a certain period of time?
    No, I did not say that RMMRP000 should be ran before requirements planning. I said it is the requirments planning. So you just run it twice if you execute it with MD01 again after this job.
    Running it twice should not end in different results if it is run with the same paramters (selection variants)
    As you are saying you get different results, I think you are running it actually with different entries in the selection screen.
    So you need to compare both selection screens. MD01 is obvious as you see it directly.
    Compare it with the selection variant of the batch job, that you can display  via the menu after you displayed the job in SM35
    ME5A transaction can give you a list of requisitions. alternative you can just use SE16 at table EBAN.
    Edited by: Jürgen L. on Apr 25, 2011 9:08 PM

  • Two Deliveries did not go through Batch Job Runing

    Hi,
    In this company every evening the automatic batch Job for Billing due list is run but on Nov 23 one Deliver and on Nov 30 another delivery has not gone through i.e. the invoices were not created for these two deliveries.
    I checked in VF01, the individual invoice is being created. The user is asking the reason for this and how to prevent this type of situation in future.
    I don't know the Batch Job number and I think it has been done in VF06.
    Please guide me how I can solve this issue.
    Thanks,
    Jans

    Hello Tushar,
    Thank you for your reply. I don't know the Variant name also and I don't know the Batch Job number eirther. The user is not aware of these things. I tried to find out from VF06 but I could not figure out anything.
    Please explain me your sentece "Execute billing program in foreground and check". you mean to say after creating the same scenario in the quality, I will run the Billing program ( I will take the Billing program from the VF01). If I am correct please let me know.
    Regarding debugging,  if I have to do how I can do it. I know to go to Debuggiing mode if I put in the command field  "/h" , I will be in the debugging mode. But my question is which transaction Should I use VL02N or VF01 to find out the Problem
    I have mentioned earlier that I went to VF01 and these deliveries are fine to create invoices but the User is interested to know the Problem and to find out the cause so that they can prevent it occuring in future.
    Thanks,
    Jans

  • Submit batch job daynamically using batch user id

    Hi,
    I need to submit the background job dynamically from ABAP program with BATCH user id.
    I have created new program. Users will execute program in foreground.
    Had issue with USER id. If I give my user id then batch job successfully creating. If I give u2018BAICHu2019 id then it is giving the error.
    Am I doing any thing wrong here?
    Code:
    Open Job
      CALL FUNCTION 'JOB_OPEN'
        EXPORTING
          jobname  = jobname
        IMPORTING
          jobcount = w_jobcount.
        SUBMIT zrufilep WITH p_file1 = sourfile
                        WITH p_file2 = destfile
                        VIA JOB jobname NUMBER w_jobcount
                        USER 'BATCH_FI'
                        AND RETURN.
    Schedule and close job.
          CALL FUNCTION 'JOB_CLOSE'
            EXPORTING
              jobcount  = w_jobcount
              jobname   = jobname
              sdlstrtdt = sy-datum
              sdlstrttm = sy-uzeit.
    Thanks

    Can any body tell me if that authorization is given to the user, can he submit any other job from front end?
    As you can see if he can, it will conflict security issues of business. So If he is not permitted to execute these kind of statements in any other program, would he be confined to using diff user in this program only?
    Or is there any other way-out to confine the user for getting this authorization for a single T-code or such?

  • Launch batch job thru SOAP call : no execution, connection OK.

    Hello,
    I am experiencing some problems launching batch jobs thru Web Services. I have added batch job "EPN_Test_Webservices" to the Web Services and enabled the Job Attributes.
    When I try to launch the job thru a SOAP call, I get a reply but the job is not executed.
    This is the SOAP envelope:
    <SOAP-ENV:Envelope xmlns:SOAP-ENV="http://schemas.xmlsoap.org/soap/envelope/" xmlns:SOAP-ENC="http://schemas.xmlsoap.org/soap/encoding/" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance" xmlns:xsd="http://www.w3.org/2001/XMLSchema">
         <SOAP-ENV:Body>
              <m:EPN_Test_Webservices_Job xmlns:m="http://www.businessobjects.com/DataIntegrator/ServerX.xsd">
                   <job_parameters>
                        <job_system_profile>String</job_system_profile>
                        <sampling_rate>10</sampling_rate>
                        <auditing>true</auditing>
                        <recovery>true</recovery>
                        <job_server>JS_ict</job_server>
                        <trace>String</trace>
                   </job_parameters>
              </m:EPN_Test_Webservices_Job>
         </SOAP-ENV:Body>
    </SOAP-ENV:Envelope>
    This is the reply I get:
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
         <soapenv:Body>
              <BatchJobResponse>
                   <pid>3888</pid>
                   <cid>13</cid>
              </BatchJobResponse>
         </soapenv:Body>
    </soapenv:Envelope>
    When I use the "ping" operation I get the following reply:
    <soapenv:Envelope xmlns:soapenv="http://schemas.xmlsoap.org/soap/envelope/" xmlns:xsd="http://www.w3.org/2001/XMLSchema" xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance">
         <soapenv:Body>
              <pingVersion>
                   <version>Business Objects Data Integrator Version 11.7.2.0</version>
              </pingVersion>
         </soapenv:Body>
    </soapenv:Envelope>
    ...which indicates the connection works. Also the "processed counter" increases, but the job does not get executed. There is nothing in the  job log, there is no result (the job is supposed to write a record in a database table). What can be wrong?

    If I run the following (on the machine I'm trying to set up the share)
    smbclient -L localhost -U%
    I got the following output
    Connection to localhost failed (Error NT_STATUS_CONNECTION_REFUSED)
    so I thought it might be something incorrect with the iptables side of things, however I haven't really touched that at all and it seems to look correct
    iptables -nvL
    Chain INPUT (policy ACCEPT 667 packets, 79977 bytes)
    pkts bytes target prot opt in out source destination
    Chain FORWARD (policy ACCEPT 0 packets, 0 bytes)
    pkts bytes target prot opt in out source destination
    Chain OUTPUT (policy ACCEPT 157 packets, 20724 bytes)
    pkts bytes target prot opt in out source destination
    So from my (very little) knowledge this appears correct (I think)... However it appears that something is blocking access somewhere.

Maybe you are looking for

  • Fail to download SCOUT on Creative Cloud Version 1.3.0.322 released on 12/19/2013

    Does anyone know how to download Scout? I'm clicking on the download button in https://creative.adobe.com/products/scout page. It opens the Creative Cloud app but nothin is downloading. Also in the Apps section of the CC Scout is not on the list, why

  • Quicktime can't read a .dv file?

    I can open the .dv file in VLC, but Quicktime gives me the error: "The document "HH Memorial.dv" could not be opened. The movie is not in a format that QuickTime Player understands."  I thought .dv was a Quicktime format?  Please help!  Thanks.

  • Problem while sending e-mail from SAP

    Hi, I need to modify customized report, my problem is i need to download as .XLS file as well i need to send as an attachment to e-mail. If i select with NO-Delimeter the attachment comming as .TXT file and if i select any delimeter that occupying on

  • Is a TSU NOTIFICATION sufficient for encryption documentation?

    I'm using an open source library for my encryption. Can I just upload my TSU NOTIFICATION as proof that I've notified BSI / NSA for the encryption documentation?

  • Order of elements in deployment.xml file

    We work in a multi-developer environment, and we syncronize our java projects reqularly. However, when one developer makes changes to the toplink project and exports a new toplink-deployment.xml, its contents can be in an entirely different order tha