Batch input session in background

hai guys,
Can we execute Batch input session in background scheduling thru jobs.
i tried with sm37. but there is not option i guess.
could you pls guide us.
ambichan.

Hi Ambi,
As Anand and Wolfgang suggested, what you need to do in your ZFB05 program is as follows. Insert this after you create the sessions.
Add parameters to your ZFB05 program for the session background processing like date, session name etc.
Then after you create your sessions, insert the following code
*-- run in the background
      CALL FUNCTION 'JOB_OPEN'
           EXPORTING
                jobname          = 'YOURJOBNAME'
           IMPORTING
                jobcount         = v_jobcount
           EXCEPTIONS
                cant_create_job  = 1
                invalid_job_data = 2
                jobname_missing  = 3
                OTHERS           = 4.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE 'E' NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
        EXIT.
      ENDIF.
      submit rsbdcsub  with mappe    = 'YOURSESSIONNAME'
                       with z_verarb = 'X'
                       with fehler   = 'X'
                       USER sy-uname
                       VIA JOB 'YOURJOBNAME'
                       NUMBER v_jobcount AND RETURN.
*-- close the job
           CALL FUNCTION 'JOB_CLOSE'
           EXPORTING
                jobcount             = v_jobcount
                jobname              = 'YOURJOBNAME'
                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.
      IF sy-subrc <> 0.
        MESSAGE ID sy-msgid TYPE 'W' NUMBER sy-msgno
                WITH sy-msgv1 sy-msgv2 sy-msgv3 sy-msgv4.
      ENDIF.
Hope this helps,
Srinivas

Similar Messages

  • Batch input session in background BDC

    Hi to all,
    Please clarify me about below BDC point.
    Call to the transaction should be in background through batch input session. does It mean that we have to use session method and call this in back ground through RSBDCSUB, is this approach is correct or some thing else i  nend to do.Please tell me briefley.
    I want to track all the errors, how to track the errrors with out using call tranaction.
    could any one help me on this issue please.
    Regards
    Raadha

    Hi,
    as per your approach is correct in BDC session method ,in session method generally you want run the bdc in backgroung using in RSBDCSUB is used for scheduling .
    in program after writing bdc_close_group ,just use submit statement and schedule the background.
    and generally in session method  execute the program and going to the sm35 selcting particular session name manually processing that session,when schedule rsbdcsub it is directly going to the background screen ,then give the session name and run the program.
    Regards,
    Madhu

  • How to run the Batch input session(SM35) in background thru Report program

    Hi Experts,
    I am working in one modification report requirement ,the report is Mass upload will update and run the file via batch input session. The client requirement is to implement the report execution in background mode , the batch input session will process automatically (ie. the job runs the batch input session in background and process the session ends).
    Currently, the report calls SM35 to write a batch input session and the user manually selects the session and record the transactions.
    Once the Transaction enters and the selection-screen inputs are given, then the transaction executed in background mode and all the above batch input process to be implemented.
    Please advise and guide me, how to proceed.
    I need your guidance to proceed via Call transaction using bdcdata statement, if it can be achieved the requirement.
    Thanks & Regards
    San.

    Hi Arabind Prasad,
    Thanks for your inputs.
    I know the process of the report Execution in background and job steps.
    I want the inputs for how to upload thru Batch input session in background job and the session should also processed automatically
    Currently the report logic declared like call transaction 'SM35' and skip first screen.Once the report (tcode) executed (not in background) It writes one session in SM35. The user should select the session and process the transaction manually.
    The new requirement is, if the report (tcode) executes in background mode...what and how the batch input session should be declared and how it process automatically (like you said mode 'N').
    Hope I am clear in my query.
    Please advise.
    Regards
    San.
    Edited by: San Learner on Mar 1, 2011 7:16 PM

  • Running Batch Input sessions in One program

    Hi Guys.
    I am sure this question might have come up before. Reall y  need quick help in this hence posted the same.
    I need to develop a program which creates several batch input sessions.
    At the end of the program all these sessions should ve triggerred in the background.
    Please let me know if this can be done and if yes can someone send me psuedocode for same.
    This is very urgent.
    thx

    Hi Vijay,
    Using the following function modules you can create a batch input session.
    BDC_OPEN_GROUP
    BDC_INSERT
    BDC_CLOSE_GROUP
    Example - http://www.sap-img.com/abap/auto-disallowed-back-posting-to-previous-period.htm
    You can use the program RSBDCSUB to schedule batch input sessions in background.
    http://www.sap-img.com/abap/learning-bdc-programming.htm - How to write BDC program
    Executing batch-input sessions in background jobs - Example for how to call the bdc session.
    Hope these are helpful.
    Thanks
    Vinod

  • How to check whether a batch input session is completed in ABAP program

    I have created a ABAP program to create a batch input session (reference to RSBDCSUB). After the creation of the batch input session, I kick it to start and read the execution log. However, sometimes I cannot read anything from the execution log as the execution of the batch input is a synchronized process to the execution of my program, i.e. at the time being that I try to read the log of a particular transaction, that transaction is being processing / haven't start processing.
    How can I check whether a batch input session is completed in the program?
    The code that corresponding to the triggering of batch input session:
    SUBMIT (SUBREPORT)
       USER MTAB-USERID
       VIA JOB MTAB-GROUPID
       NUMBER JNUMB
       WITH QUEUE_ID  EQ MTAB-QID
       WITH MAPPE     EQ MTAB-GROUPID
       WITH MODUS     EQ 'N'
       WITH LOGALL    EQ LMODUS
    Or is there any method to wait here until the process is completed before further processing?

    Hi gundam,
    1. Or is there any method to wait here until the process is completed before further processing?
    There is no such direct method to wait.
    2. Immediately after submitting in background,
       we cannot wait
      neither can we LOOP and go on detecting
      whether the b/g process has completed or not !
    3. To over come such problems,
      we have to use another technique.
    4. we have to submit another
       job which will get triggered
       on event SAP_END_OF_JOB
       ie. when the original job will finish,
      our new job will AUTOMATICALLY get triggered,
    5. This new job / program
       will do the FURTHER actions !
    regards,
    amit m.

  • Batch Input error in background in fb05

    Hi All
    I am trying to clear vendor open  items for document numbers from BSIK table.
    i am doing this using fb05 transaction, checking the 'post with clearing' option.
    The program creates a batch input session.
    When i process the session in foreground, the vendor document is cleared and a new clearing document is posted.
    However, if i try to process the session in background , we get the error "Difference too large for clearing". The error is shown in program SAPMF05A and screen number 700.  Whereas, my recording does not have this screen number .
    Even when i anlyze the session screen flow, i do not see this screen number.
    Any pointer on the issue shall be of great help.
    Thanks
    Pankaj

    Hi
    thanks for the pointer.
    I agree that we get this error if the items are not selected.
    Could it be that the items are activated by default in foreground mode , and deactivated in the background mode?
    Moreover, could you please give some more info about " the std bi RFBIBL00, it supports the trx FB05" ?
    Thanks
    Pankaj

  • LSMW- Batch Input session getting error

    Hi All,
    I created LSMW object for Tcode KO01 and its creating the Internal order as expceted.But even after creating the document the Batch Input session status is showing incorrect.No messages are also displayed in the log.
    Please let me know why this is happening.
    Thanks in Advance,
    Savitha

    Hi,
    Detail Error Message is as follows:
    No batch input data for screen SAPLIMR0 1110
    Message no. 00344
    Diagnosis
    The transaction sent a screen that was not expected in the batch input session and which therefore could not be supplied with data.
    Possible reasons:
    1. The batch input session was created incorrectly. The sequence of screens was recordly incorrectly.
    2. The transaction behaves differently in background processing in a batch work process than when running in dialog (SY-BATCH is queried and changes the screen sequence).
    3. The transaction has undergone user-specific Customizing and therefore certain screens may be skipped or processed differently, according to the current user. If the person who created a batch input session is not the same as the person now processing it, this problem may occur frequently.
    System Response
    None.
    Procedure
    For 1: Either re-create the session or process it in expert mode. Correct the batch input program.
    For 2. It is very difficult to analyze this problem, particularly in the case that the screen sequence or the display-only options of fields differ according to whether the transaction is being processed in the background or as an online dialog. It could also be that this kind of transaction cannot run with batch input.
    For 3: Have the creator of the session process it. If no error occurs now, then this is a program with user-specific Customizing.
    Regards,
    ababfk

  • Batch inputs sessions got deleted

    Dear All,
    We have a major issue on our SAP Production server. We have executed the report RSBDCTL2 as a background job RSBDCTL2_300 on 29th May 2010 with delete option. This has deleted all the batch input sessions that were existing in SAP Production server. It has impacted severly our monthly closing.
    We have also executed the report RSBDCREO which have deleted the logs of these sessinos as well.
    We want restore all those sessions on priority. Please, suggest immediate work around. (Apart from restoring the backup)
    Thanks and Regards,
    Kedar

    Rishi,
    RSBDCTL2 jobs deletes the sessions that exists in SM35. Rescheduling the jobs wont help. Also restore is not the right option as we might have to restore the backup of 28th May i.e. 4 days old.
    Is there any other option or report that can restore these sessions?
    Thanks and Regards,
    Kedar

  • CO40 batch input sessions

    Hi Gurus,
    We schedule background jobs to convert Planned order to a Production order using program PPBICO40. This program/job is generating batch input sessions, weekly we go to SM35 and delete these sessions manually. This is becoming a weekly maintenance task.
    Would like to know is there a way to get rid of these sessions, without deleting them manually or is there any setting that the program PPBICO40 do not generate batch input sessions whenever it runs in the background. We are using 4.6c.
    Thanks in advance
    Srini

    Hi,
    There is noway to get rid of this. At least you need to give some inputs, then only the system will consider that particular inputs for the background job. You can create a variant, but eventhough you need to give some inputs.
    Regards,
    V. Suresh

  • Please help  me with some questions with batch input session?

    hello everyone.
      I come to some questions  like
    1 What is a batch input session ,
    2  What is the alternative to batch input session?
    3  An ABAP program creates a batch input session.   We need to submit the program and the batch session in back ground. How to do it? 
       would you please help me with the questions, couldn't thank you more.
       Best regards
                                                                          Frank

    Hi
    Batch Input Session:
    BATCH INPUT SESSION is an intermediate step between internal table
    and database table. Data along with the action is stored in session
    ie data for screen fields, to which screen it is passed, program
    name behind it, and how next screen is processed.
    Three processing modes of executing Batch Input Session :-
    Run Visibly : You can correct faulty transactions online & work step-by-step through  the transactions not yet executed.
    Display Errors only : You can correct faulty transactions online.   Transactions not yet executed, but without error, run in the background.
    Run in Background .
    2) What is the alternative to batch input session?
    Call transaction.
    3) An ABAP program creates a batch input session. We need to submit the program and the batch session in back ground. How to do it?
    go to SM36 and create background job by giving
         job name,job class and job steps (JOB SCHEDULING)

  • Batch input session to FB01 using standard program RFBIBL00

    Hi all,
    I am creating a batch input session using the standard program RFBIBL00 to simulate transaction FB01.
    My problem is when I process the "batch input session" (using transaction SM35), this finish ok, but in the log I am retrieving the following message:
      "Field BSEG-DMBTR. does not exist in the screen SAPMF05A 0300"
    This is a success message and the document is created ok,and the field DMBTR is informed ok.
    Has somebody some idea?.
    Thanks so much in advance for any answer.

    Hi gundam,
    1. Or is there any method to wait here until the process is completed before further processing?
    There is no such direct method to wait.
    2. Immediately after submitting in background,
       we cannot wait
      neither can we LOOP and go on detecting
      whether the b/g process has completed or not !
    3. To over come such problems,
      we have to use another technique.
    4. we have to submit another
       job which will get triggered
       on event SAP_END_OF_JOB
       ie. when the original job will finish,
      our new job will AUTOMATICALLY get triggered,
    5. This new job / program
       will do the FURTHER actions !
    regards,
    amit m.

  • Batch input session for Recurring Entry

    Hello All,
    i have created Batch input session for Posting document's for recurring entries creted and job executed in background through SM35 and done successfully, but i am unable to find the Batch input session in SM35 which i have created to run the job.
    i want to see the log file for this Batch Input session.
    Please help me how to get the batch Input Session.
    Thanks
    Shankar

    Hi Murali...
    Thank you a lot for your answer, i have created the Batch input session without selecting the "HOLD Session" Check box..
    Issue Resolved
    Thanks Again
    Shankar

  • Batch Input Session - Display Error Only - SM35

    Dear all,
    Need to do material master extension in MM01 and considering batch input session using mode 'display error' only.
    However,do have a concern on its performance or run time. In SM35, running in display error only mode - will there be any time out error like the ones encounter in abap reporting ?
    This is because, we will be dealing with a huge volume of data (round 2,000). Therefore would like to know, if there would be any possibility that the bdc session in sm35 will experience a time out or not .
    Appreciate it if you could shed some lights on this. Thanks in advance.

    Hello there,
    Executing MM01's batch job in background wasn't really an option. This is because, this error was encountered "Control Framework: Fatal error - GUI cannot be reached".
    Had done a search on this -- and it indicates that in background mode there isn't GUI involved. Searched result also shows that this error appears when its comes to screens with text ie. Purchase Text or Sales text. Nope, no BDC on entering text involved.
    http://www.sapfans.com/forums/viewtopic.php?f=13&t=164902&hilit=ControlFramework%3AFatalerrorGUIcannotbe+reached
    Therefore the option am considering is executing the batch job in "Display Error Only". Nonetheless, am not too sure if this will cause time out. The other reason as to this option is that -- we initially introduced CALL TRANSACTION for extending material in MM01. However, functional feedback that it was slow.
    Kindly advise - thanks in advance.

  • Batch input session in n-joy sap transaction

    Hello experts,
    I am trying to update data through a batch input session using transaction KE21N.
    there are 258 records.
    The problem is when I run the session in background, all of the records are errored and not updated.
    But when I process them using 'display errors only/foreground'.
    some of the are updated ( the rest are becuse the material is not in the tables).
    I want to know if we can run the background process, so that the correct fields can be updated.

    Generally, you should not use EnjoySAP transactions in batch input - particularly in the background. SAP keeps the old transactions around for just this purpose. So try transaction KE21.
    Rob

  • SM35: Batch-Input Session cannot be released / RSBDCBTC

    Hi,
    a job with ABAP RSBDCBTC, which processed a batch input session, was cancelled due to system shutdown.
    Now the sm35-session has got status 'In processing' and cannot be released ( Message 00299: Could not release folder MM06_XXXX, since it still contains a background job).
    A new Job finishes with 'The requested session cannot be processed'.
    Is there a possibility to get the batch-input-session released ?
    Wolfrad

    Hi,
    It seems the Batch Input Session had schedule a background job which is still running & hence cannot be released.
    Could you please check in transaction SM37 whether any related background job is still running.
    Select the job & click on Cancel to stop the job. Then retry to release.
    Best regards,
    Prashant

Maybe you are looking for

  • Safari Developer Program License Agreement: We are unable to process your request

    Hi all, I'm trying to sign up for the free Safari Developer Program.  Everything proceeds as normal until the step Agree to License[1] after which point I receive the message "We are unable to process your request."  I have tried to logout of the Mem

  • Changing libraries on iTunes

    I have an external hard drive where I store all my music files and I use this interchangeably between my work and home computer with home being where I synch my iPod. Well, the other day, I was on my work computer with the external drive plugged in a

  • EAS question

    Hi Team, I have installed EAS client on my desktop and I have essbase 11.1.2.2 running on another server. I can connect using Excel addin to the essbase server. I am not able to connect to the Essbase server from desktop EAS client and I am getting a

  • Get rid of those annoying extra ' ' characters

    Always use the < escape instead of a literal '<', even in [code] blocks. Otherwise, the forum software will try to help you out by throwing in a '>' to balance it. It usually inserts the character at the end of the post, but if there's another '<' an

  • Are imessages stored on apple server and how to delete

    are imessages stored on an apple server, if so , how would i permanently delete these ? i could not find an imessage help guide on the apple website thanks