Problem with back ground job

Hello experts,
I have one background job which generates a text file and place it in a FTP folder.
When one user runs this job its working fine. But,
When two users run <b>the same background job at same time,</b> then i get trouble with my output file as the data is mixed up.
How to avoid this!  Appreciate quick response.

Have each run of the job create a unique file  OR  when a user starts a job, create a "marker" file that prevents all other runs of the same prg from executing until the marker file is deleted.
The deletion of the marker file would need to be the last step of the prog then.  This would allow the second user to run the prog later (after the first user is done).

Similar Messages

  • Problem with Back ground MRP Run (MDBT) or MD01

    Hello SAP Experts,
    Issue :- Material is not considering during Automatic back ground MRP run ( MDBT or MD01)
    But when we run MRP in forground (MD02) system is considering the material.
    we have checked both the selection parameter are same for MD01 and MD02 .
    can you help us on this issue ?
    Regards
    Mahesh

    Hi,
    Problem is due to entry in Planing File is missing for that Material.
    Go to MD21 and check whether Planing File entry is maintain for that Materiel.
    If not then maintain it by T.code MD20 (Manual) or you can do it by using back Ground JOB - OMDU.
    Regards,
    Dhaval

  • How To Handle With Back Ground JOB From WEBUI When Click On "Appove"

    Hi
    How To Scheduled A Job Through ABAP Report In back end  Of CRM when i click on "Approve" Button in WEBUI  From result list.
    As per My requirement I have a Search View and Result View
    In Search View I have  Below Fields
    ITC Vendor ID    
    Claim Status
    User status (date status changed)
    Model
    Serial Number
    Date completed of Service Completion
    Based on Search Criteria I will get Result In Result View.(Suppose 10 Records I got In Result View)
    In the Result View I need to Add one Button As "Approve"
    When i Click On Approve button One Pop up Message Need to Open And In that popup window I need to Display Below Text
    "Approve  Claim Job Has Started In Background  
    Note: Only Claims Which are in Submitted  Status  Will be  Approved. you May Close This Window"
    In SAP CRM System  Back Ground Job Need To Start When Click On "Approve" Button In WEBUI .
    In the Back Ground ABAP Report which will validate based on Result List Records"
    In the Result List we may have all types of Claims which are status in "Submitted" "Pending" "Rejected" "Approve".
    I need to collect all records from Result list and validate Those Records who's Status in "Submitted
    1)Sort all the claims based on ITC Vendor ID.
    2)Grouped all the submitted claims against each ITC Vendor ID from the search result
    3)Change the status of the selected submitted claims to Approved.
    4)Displays information messages as mentioned whenever a claim is approved, the same message will be captured in the job log.
    ‘Claims <ClaimID 1>,…<ClaimID N> now approved for ITC Vendor ID’.
    5)Sending Email to each IRC.
    6)Capture all the approved claims in the below format (Format Attached "Screen Shot Attachment")
    7)Store the file in the Application Server AL11 in .csv format
    Please Find Attachement For Reference.
    1)ITC Claim Screen Shot
    2)Screen Shot For Attachment
    Thanks
    Raj

    Hi,
    You can add the following code in on approve method to show popup to the user,
    IF req_edit IS NOT BOUND. " gloabl attribute in impl class of the view
        REFRESH lt_buttons.
        lss_button-id  = 'btnyes'.
        lss_button-text = 'YES'.
        lss_button-on_click = 'YES'.
        APPEND lss_button TO lt_buttons.
        CLEAR lss_button.
        lss_button-id  = 'btnno'.
        lss_button-text = 'NO'.
        lss_button-on_click = 'NO'.
        APPEND lss_button TO lt_buttons.
        CLEAR lss_button.
        CALL METHOD comp_controller->window_manager->create_popup_2_confirm
          EXPORTING
            iv_title          = 'ATTENTION'
            iv_text           = 'Are you sure you want to edit this document?'
            iv_btncombination = '99'
            iv_custombuttons  = lt_buttons
          RECEIVING
            rv_result         = req_edit.
        req_edit->set_on_close_event( iv_event_name = 'EDIT' iv_view = me ). "#EC NOTEXT
        req_edit->open( ).
        RETURN.
      ELSE.
        lr_node ?= req_edit->get_context_node( 'OUTPUTNODE' ).
        lv_outbound = lr_node->get_event_name( ).
    *  CLEAR ptc_pricing_status.
    *    lv_outbound = req_edit->get_fired_outbound_plug( ).
        IF lv_outbound = 'YES'.
    you can use the submit report code here and you can al the validations here
        ELSE. " No
    if user clicks no nothing to do..
        ENDIF.
        CLEAR req_edit.
      ENDIF.
    Best Regards,
    Dharmakasi.

  • Problem in Back Ground Job

    Hi Experts,
    I want to execute a program in Back ground but my program has selectionscreen.
    I don't want to Provide Variant for this screen that's why i am passing these values Thru INITILIZATION event.
    But Background is not moving forward. It is waiting for I/p.
    Can you please help me on this.
    Thanks,
    Murali Krishna K

    Murali,
    For a program to be executed in background you need to create a variant and provide the variant name in the def. of the background job. giving the values at INITIALIZATION  will NOT work.
    On the second thought, you might have declared your parameters as OBLIGATORY. Take out that and make them optional. Now you schedule this in background without a variant and give the values in the INITILIZATION event.
    Regards,
    Ravi
    Note : Please close the thread of the issue is resolved.
    Message was edited by: Ravikumar Allampallam

  • Relating with back ground jobs

    hi gurus,
    i have 3 fields on sel-screen.one for date of creation of sales order in range and three radiobuttons for yearly, quartly and monthly display of sales order.
    i am creating this pgm  to run in background.
    pls, help me out to write a logic to break varint at run time.
    for eg. if i m inputin 1jan 2007 to 15 feb 2007 than on monthly selection it should give 2 steps:  1 for 1jan to 31 jan and 2nd
    for 1feb to 15 feb.
    similarly, on quartly selection it will retrieve for 1jan to 15 feb.
    pls, help me out to write a logic for this requirement.
    it is very urgent...
    pleeesee  reply it immediatly

    Hi,
    write a second report splittin dates as subscribed. SUBMIT the already existing report several times.
    Spool might be a problem - EXPORT spool to MEMORY and IMPORT might solve the problem.
    Better: plan differnt steps of the jopb for each period. If thsi must be done dynmically you may use function JOB_START to shedule jobs at runtime.
    have fun,
    HP

  • Submit Back ground job with error log

    Hi Gurus
    Can anyone help with Back ground job with error log. i want put all the error logs in to 1 internal table and submit the back ground .how can i do that .please help me

    Hi reddy ,
    i am not experienced this in real scenarion .. even though i would like to give my idea
    Put your logic inside the FM and execute in in background task mode on your action button .
    call function 'Function module name' in background task
    exporting
       parameter =
    importing
       ret =
    refer the below link for more detail on executing FM as  background task
    http://help.sap.com/saphelp_nw70ehp1/helpdata/en/8f/53b67ad30be445b0ccc968d69bc6ff/frameset.htm
    Regards
    Chinnaiya P

  • Back ground job problem

    hi every  one,
      pls help me out in this.
      i have written a program to create a wbs element.as it takes  20 to 30 min to create one element in production.in my program, there is part of code which creates wbs elements.
    so i want to run tht part of code in background.
    only part of code.
    even i did the coding for it. i wrote  a new program and i pasted that part of code in new program.
    and this new program i m submitting in old one by creating a back ground job.
    i m exporting few required internal tables for new report.i hav imported all internal tables in new report also..
    but still this importing exporting is not happening..pls
    tell me wat can be the problem..
    thanks..

    Your code is not optimized according to performance,can you sed me your code ...
    see my business card  for my  id.
    Thanks

  • Back Ground Job Printing Problem

    Dear Experts,
    We schedled one back ground job with spool generation. Ecery thing is working fine but in printing selecton parameters are printing along with out put data.
    That means, if i gave 1000 materials in my variant, in spool first 1000 materials are printing an then actually out put is printing. i need to avoid these printing of selection set.
    Please help me...
    Thanks in advance

    Hello,
    Pleas find if there is any "PRINT_SELECTION" function module in report, which should be responsible for printing selection screen parameter values.
    Thanks.

  • Schedule the Back ground Job with Fiscal Year Vaient????

    Hello Guru's,
    Please let me know the process of "Schedule the Back ground Job with Fiscal Year Vaient" in APO DP?
    Great thanks for your help.
    Regards,
    Sree

    Hi Venkat,
    As i told i am maintaining the periods as 5-4-4, So i want schedule the job as first after the 5th week, then after the 4 th week, then after the 4th week and again after the 5th week ...... like that....
    can we schedule the job in back ground as per this periodically???
    Thanks for the response.
    Regards,
    Sree!!
    Edited by: sree gunti on Nov 26, 2008 3:30 PM

  • Scheduled back ground job not finishing

    hie gurus, i need your help with back ground scheduling , i have created a background schedule to run my program after every 30min .  in the job overview it shows my job released and active but its not finishing processing . the program being run picks up data from an external data base and then inserting via BDC call transaction. i have tried with a different program that inserts data into a database table and its executing and finishing well in the back ground. What could be the problem ? and how can i debug a back ground job ??

    Daniel,
    To start, BDCs are very out-dated.  I would look for a BAPI if you are calling std SAP functionality.
    Also - direct updates into std SAP tables is a HUGE "no-no"... I hope that you are updating custom tables only.
    Pass that - to debug a b/g job---> 
    1) Set a breakpoint in your program
    2) select the job in SM37
    3) enter JDBG into the SAP fastpath of the SM37 screen and press ENTER
    This will navigate you into a b/g debug - you can then press the debugger buttons to move to your breakpoint.
    Hope that helps.

  • Create Back ground job for data recieved from a legacy system

    Hi All,
    I have a requirement where i need to schedule a back ground job once a proxy is triggered for the address data sent from a Legacy system. This proxy is triggerred from SAP PI, then i need to create a job shedule where address data is created as BP's(Business Partners) and assigned to a already created Target Group. Then once the Target group is completed with all BP needs to assigned to aCampaign Id. As the data is large it takes lot of time to execute. Please Advice.
    Regards,
    Nagesh Thanneeru

    Hi
    If you can divide the data into two internal tables and later collect into the one internal table, this could solve yuor problem.
    Also you need to make sure that enough memory is available in the system. Check DB6cockpit for that.
    Also there are a lot of correction notes available with SAP for the error"TSV_TNEW_BLOCKS_NO_ROLL_MEMORY"
    Check what the job exactly does, and search for the relevant notes, as there are different notes for different application areas...
    if its a loading job(Infopackage) you can reduce the data packet size of the IP, but that might hamper the loading performance.
    Hope this helps
    Regards
    Shilpa

  • Back Ground Job scedule (emergency)

    Hi all ,
    I have scheduled Back Ground Job in Production System at morning 11am, now the job is in running status,but i wonder that before the status come to completed the
    LAST RUN Column is filled with Date and time same at 11:am.
    Please find the below job log details i am pasting last few lines of job log
    Jun 5, 2008 2:15:22 PM com.virsa.cc.xsys.riskanalysis.AnalysisEngine performActPermAnalysis
    INFO:  Job ID:6 : Before GC => memory usage: free=481M, total=1009M
    Jun 5, 2008 2:15:22 PM com.virsa.cc.xsys.riskanalysis.AnalysisEngine performActPermAnalysis
    INFO:  Job ID:6 : Analysis starts: HTREMGMT2
    I would like to know wheather job is running or terminated.
    Wat is the sequence of JOB status in CC5.2.
    Kindly do the needfull.

    Hi Amol,
    Thank You very much for ur quick reponse,
    please find the view job log details
    (last few lines)
    Jun 5, 2008 3:07:12 PM com.virsa.cc.xsys.riskanalysis.AnalysisEngine performActPermAnalysis
    INFO:  Job ID:6 : 464 out of 818 (56%) done
    Jun 5, 2008 3:07:12 PM com.virsa.cc.xsys.bg.BgJob setStatus
    INFO: Job ID: 6 Status: Running
    Jun 5, 2008 3:07:12 PM com.virsa.cc.xsys.riskanalysis.AnalysisEngine performActPermAnalysis
    INFO:  Job ID:6 : Before GC => memory usage: free=347M, total=1009M
    Jun 5, 2008 3:07:12 PM com.virsa.cc.xsys.riskanalysis.AnalysisEngine performActPermAnalysis
    INFO:  Job ID:6 : Analysis starts: MACTUSER17
    Jun 5, 2008 3:07:21 PM com.virsa.cc.xsys.meng.ObjAuthMatcher <init>
    FINEST: ObjAuthMatcher constructed: 0ms, #singles=970, #ranges=0, #super=0
    Jun 5, 2008 3:07:22 PM com.virsa.cc.dataextractor.bo.DataExtractorSAP getObjPermissions
    FINEST: getObjPermissions: elapsed time=891ms
    can u tell me the job status sequence

  • Back ground job work in MM

    CAN ANY BODY TELL ME WHAT IS A BACK GROUND JOB WORK IN MM pls explain it with good example tell me 1 or  2back ground job work relevent transactions
    good answer will be awarded
    kiran

    Hi,
    Background job means system will automatically perform some transaction / actions at perdetermined time based on the variants selected for that program.
    Ex 1: You want to see the list of PO or PR or Production order created for a day, you can create a ABAP program and give the creation date in selction screen.
    Provide the Plant or doc type, file path to download the report etc..
    and save the variant.
    You can set this program to run during mid night( 11.00 p.m) with the sysytem date (crrent date).
    So system will run this program and extract the report in Application server level as per the file location given in the program selection screen.
    Ex 2:
    MRP program
    Ex 3.
    Auto PO creation program
    Thanks,
    Kumar Arcot

  • How to reschedule a Back ground job in Normal ABAP from Web Dyn Pro abap application??

    Hi Experts,
    How to reschedule a Back ground job in Normal ABAP from Web Dyn Pro abap application??

    Can you give us some more information? Background jobs primarily don't have anything to do with Webdynpro.

  • Back Ground Job Issue

    Hi,
    My report program was executing successfully in the Foreground but not in the back ground.. Can any one help me on this?
    My report program has a selection screen..I entered the data for it at and through menu option Program->execute in background..I executed it..As it asked for output device i gave LP01 and No of copies to 1. and checked Radio button Print all. and clicked ok.
    It asked me for start time and i selected Immediate and clicked on save.
    It gave a status message "Back ground Job Scheduled".
    Now when i look through SM37 under my name the job is always active and Never finished.
    Can any one help me on this?
    Thank in advance..

    Just check whether the job is running in the background or not
    Double Click on the job name and take the Server & Process Id.
    Go back to the SM37 Screen.
    Click on Application Servers or directly Open the transaction SM51.
    Select the Server and find the process Id with the help of the things you found already
    Now, you can see the database level.
    Check if the values or moving or not. This way you could track the details
    If not, Ask BASIS guys to check whether the job is reading from rollback or not.
    If it is, cancel and rerun the job...or else..leave the job..it will finish off in some time.
    Hope everything is clear

Maybe you are looking for

  • How to create a link with 2 choices in Xcode: one selected with UICollectionViewController and the other with UITableViewController

    Hi I want to create a app redirecting to my mebsite.This app permit to select a "area" selected on a UICollectionViewController, and an "event" selected with a UITableViewController. I need to integer both informations on the FinalViewController (cal

  • Pass a value to an item renderer button

    I have a datagrid.  One of the columns has a value of "@recipe", with is a string that's a URL. I need to replace this with a link button that goes to this url. So I created an Item Renderer: <?xml version="1.0" encoding="utf-8"?> <mx:Canvas xmlns:mx

  • Do child schema element inherit namespaces of parent?

    I have following declaration in my BPEL's wsdl file - <xs:element name="iamcomplex" xmlns:xs="http://www.w3.org/2001/XMLSchema"> <xs:complexType> <xs:sequence> <xs:element name="complexpartone" type="xs:string" /> <xs:element name="complexparttwo" ty

  • Stand by database

    Hi guys, OS: Windows Server 2003 (32 bit) DB Version: 10.2.0.3 Question: Simple question I guess but still I'm failing to understand the logic. Will the changes applied on the primary database also occur in the stand-by, for instance if I delete a ta

  • FilePermission in J2EE server

    Hello. I want to delete files in a certain folder in a web component in the J2EE server using JSP. When I try to call File.delete(), it is rejected because file access denied. How can I control the file permission in J2EE? I tried to add to JDK java.