Problem in item data updation in Opportunity Creation

Hi All,
I am able to create the opportunity with BAPI_OPPORTUNITY_CREATEMULTI but the item data ( product tab in the opportunity ) is blank.
Please see the code below which i am using for this item data population. Update is getting terminated if i am using header handle. Please send me the correct solution for this problem.
*set item data
  clear ls_input_field.
  ls_input_field-ref_handle  = lc_handle_2.
ls_input_field-ref_kind    = 'B'.
  ls_input_field-objectname  = 'ORDERADM_I'.
  ls_input_field-fieldname   = 'HANDLE'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname   = 'HEADER_HANDLE'.
  INSERT ls_input_field INTO TABLE lt_input_field.
ls_input_field-fieldname     = 'LOGICAL_KEY'.
INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname   = 'ORDERED_PROD'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname   = 'NUMBER_INT'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname   = 'MODE'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  lv_item = 0.
  lv_number_int = 0.
  ls_item-handle               = lc_handle_2.
  ls_item-header_handle        = lc_handle_1.
ls_item-parent_handle        = lc_handle_1.
  if i_form_id = 'CAP'.
    ls_item-ordered_prod       = 'CAP_FEE'.
    ls_item-number_int = lv_number_int + 10.
    ls_item-mode               = 'A'.
    append ls_item to lt_item.
    lv_number_int = ls_item-number_int.
    clear ls_item.
*set schedule line
  clear ls_input_field.
  ls_input_field-ref_handle  = lc_handle_2.
  ls_input_field-objectname  = 'SCHEDLIN'.
  ls_input_field-ref_kind    = 'B'.
  ls_input_field-fieldname     = 'ITEM_HANDLE'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname     = 'HANDLE'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_input_field-fieldname     = 'QUANTITY'.
  INSERT ls_input_field INTO TABLE lt_input_field.
  ls_scheduleline-item_handle = lc_handle_2.
  ls_scheduleline-handle      = lc_handle_1.
  ls_scheduleline-quantity    = 1.
  append ls_scheduleline to lt_scheduleline.
  endif.
- Prakash

Hi,
Use the below code to maintain line items, in FM 'CRM_ORDER_MAINTAIN'.
          CREATION OF THE ITEM GUID
            CLEAR v_item_ref_guid.
            CALL FUNCTION 'GUID_CREATE'
              IMPORTING
                ev_guid_16 = v_item_ref_guid.
          CREATION OF SCHEDULING LOGICAL GUID.
            CLEAR v_sched_logical.
            CALL FUNCTION 'GUID_CREATE'
              IMPORTING
                ev_guid_16 = v_sched_logical.
          values for it_pricing
            CLEAR wa_pricing.
            CLEAR it_pricing.
            wa_pricing-ref_handle = c_ref_handle2.
            wa_pricing-ref_guid   = v_item_ref_guid.
            wa_pricing-ref_kind   = c_b_kind.
            INSERT wa_pricing INTO TABLE it_pricing.
          values for product_i-UOM
              CLEAR wa_product.
              CLEAR wa_fieldname.
              CLEAR it_fields.
              wa_fieldname-fieldname = c_process_qty_unit_field.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_input_field.
              wa_input_field-ref_handle   = c_ref_handle2.
              wa_input_field-ref_guid     = v_item_ref_guid.
              wa_input_field-ref_kind     = c_b_kind.
              wa_input_field-objectname   = c_product_i_input.
              wa_input_field-field_names  = it_fields.
              INSERT wa_input_field INTO TABLE it_input_field.
              CLEAR wa_product_i.
              wa_product_i-ref_guid         = v_item_ref_guid.
              wa_product_i-ref_handle       = c_ref_handle2.
              wa_product_i-process_qty_unit = wa_product-process_qty_unit.
              INSERT  wa_product_i INTO TABLE it_product_i.
            ENDIF.
          values for service_i
            CLEAR wa_input_field.
            wa_input_field-ref_handle   = c_ref_handle2.
            wa_input_field-ref_guid     = v_item_ref_guid.
            wa_input_field-ref_kind     = c_b_kind.
            wa_input_field-objectname   = c_service_i.
            wa_input_field-field_names  = it_fields.
            INSERT wa_input_field INTO TABLE it_input_field.
            CLEAR wa_service_i.
            wa_service_i-ref_guid   = v_item_ref_guid.
            wa_service_i-ref_handle = c_ref_handle2.
            INSERT wa_service_i INTO TABLE it_service_i.
          fieldnames for quantity
            CLEAR wa_schedul.
            READ TABLE it_schedul INTO wa_schedul INDEX 1.
            IF sy-subrc = 0.
              CLEAR wa_fieldname.
              CLEAR it_fields.
              wa_fieldname-fieldname = c_logical_key.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_fieldname.
              wa_fieldname-fieldname = c_quantity.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_input_field.
              wa_input_field-ref_handle   = c_ref_handle2.
              wa_input_field-ref_guid     = v_item_ref_guid.
              wa_input_field-ref_kind     = c_b_kind.
              wa_input_field-objectname   = c_schedlin_input.
              wa_input_field-logical_key  = c_log_key_item.
              wa_input_field-field_names  = it_fields.
              INSERT wa_input_field INTO TABLE it_input_field.
              CLEAR wa_quantity.
              CLEAR it_quantity.
              wa_quantity-guid          = v_sched_logical.
              wa_quantity-item_guid     = v_item_ref_guid.
              wa_quantity-quantity      = wa_schedul-quantity.
              wa_quantity-logical_key   = c_log_key_item.
              wa_quantity-handle        = c_ref_handle0.
              INSERT wa_quantity INTO TABLE it_quantity.
            valus for quantity
              CLEAR wa_schedulin.
              wa_schedulin-ref_guid   = v_item_ref_guid.
              wa_schedulin-ref_handle = c_ref_handle2.
              wa_schedulin-schedlines = it_quantity.
              INSERT wa_schedulin INTO TABLE it_schedulin.
            ENDIF.
          fieldnames for product
            CLEAR wa_orderadm.
            READ TABLE it_orderadm INTO wa_orderadm INDEX 1.
            IF sy-subrc = 0.
              CLEAR wa_fieldname.
              CLEAR it_fields.
              wa_fieldname-fieldname = c_itm_proc_ident.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_fieldname.
              wa_fieldname-fieldname = c_mode_input.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_fieldname.
              wa_fieldname-fieldname = c_ordered_prod.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_fieldname.
              wa_fieldname-fieldname = c_number_int.
              INSERT  wa_fieldname INTO TABLE  it_fields.
              CLEAR wa_fieldname.
              wa_fieldname-fieldname = c_prog_id.
              INSERT wa_fieldname INTO TABLE it_fields.
              CLEAR wa_input_field.
              wa_input_field-ref_handle   = c_ref_handle2.
              wa_input_field-ref_guid     = v_item_ref_guid.
              wa_input_field-objectname   = c_orderadm_i_input.
              wa_input_field-field_names  = it_fields.
              INSERT wa_input_field INTO TABLE it_input_field.
            values for product
              CLEAR wa_orderprp_i.
              CLEAR v_itemno.
              v_itemno = v_itemno + v_line_incr.
              wa_orderprp_i-guid          = v_item_ref_guid.
              wa_orderprp_i-header        = v_head_ref_guid.
              wa_orderprp_i-number_int    = v_itemno.
              wa_orderprp_i-ordered_prod  = wa_orderadm-ordered_prod.
              wa_orderprp_i-description   = wa_orderadm-description.
              wa_orderprp_i-handle        = c_ref_handle2.
              wa_orderprp_i-number_int    = wa_orderadm-number_int .
              wa_orderprp_i-zzprogram_id  = wa_orderadm-zzprogram_id.
              INSERT wa_orderprp_i INTO TABLE it_orderprp_i.
            ENDIF

Similar Messages

  • User exit for PO Item data update

    Hello All,
    At time of creation of PO using ME21N / ME58, we want to update PO item data . We want to update Over and Under delivery tolerances values from corressponding sales order rather than purchase info record.
    Please let me know if anyone has worked on similar requirement or any pointers for relevant user exits in SAP Release 4.6C .
    Regards,
    Manu.

    Hello ,
    Would you please check the below Userexits in 4.6C .
    EXIT_SAPLV50E_001
    EXIT_SAPLV50E_002
    EXIT_SAPLV50E_003
    EXIT_SAPLV50E_004
    EXIT_SAPLV50E_005
    EXIT_SAPLV50E_006
    In which I hope 2 and 4th were usefull.
    Regards,

  • Problem: Z table data updates using SM30

    Hi,
    I have a requirement, while updating records in a Z table
    using SM30 Transaction.
    The Structure of the table is below:
    APMOD    Primary Key   Char(3)
    KONST    Primary Key   Char(20)
    ENDDA    Primary Key   DATS
    BEGDA    Non Key       DATS   
    and some other non key fields....
    Problem:  This table should act something like Infotype in HR.  I mean Delimition of Records while creating or changeing the existing record.
    Say there is a record
    APMOD = OGMT
    KONST = Organization Management
    BEGDA = 01/01/2004
    ENDDA = 12/31/9999
    Whenever i am Inserting a new record with key
    APMOD = OGMT and KONST = 'Organization Management'
    and BEGDA = '01/01/2006'.
    First it should update the old record with
    BEGDA = 01/01/2004 and ENDDA = 12/31/2005
    Then the new record needs to be inserted with
    BEGDA = 01/01/2006 and ENDDA = 12/31/9999.
    How can I achieve this using SM30? Can we write our own code somewhere? If yes Where and How?  Or is there any settings available for this requirement?
    I can write a Z program to update this Table, but i should achieve this using SM30 only.
    Let me know if you need any additional info. 
    Regards,
    Sudhakar.

    Hi Sudhakar,
    1. I tried the same at my end. It works fantastic !
       In  SM30 it shows
       'Delimit' Button
       'Expand <--> Collapse' Button.
        and accordingly delmits the records.
    2. in SE11,
       Use the menu
       Utilities ---> Table Maintenance Generator
       and finally build a table maintenance
       to use in SM30.
    3. When u use in SM30,
       u will achieve what u want.
    4. Just make sure your field
       ENDDA has the data element ENDDA
       in table definition.
      It should also be key.
    5. After this ENDDA column,
       there should be no other key column
      ( not even BEGDA)
    I Hope it helps.
    Regards,
    Amit M.

  • Workflow for creating new item and updating list

    I believe that the answer is easy, but because I am already having trouble with this issue for few days I am getting blind to see the solution:)
    I have two lists and a workflow running behind. Basically when new item is created in first list, workflow makes a copy in second list. Because this workflow works only when new item is added, I have a problem when item is updated, items in second list just
    disappear - are empty. I believe that I have a problem with workflow, because somehow I should also have in to update list in case of change.
    Please help.
    Thanks in advance

    Hi,
    According to your description, my understanding is that the workflow you created was not started when an item was updated in first list.
    Did you check the option “Start workflow automatically when an item is changed” in SharePoint Designer?
    Did you sign in as system accout?
    Please use another list to check whether this issue occurs.
    If this issue still occurs, please provide screenshot about the details of the workflow in order to find out what goes wrong.
    Thanks,
    Dean Wang

  • Problem with item and/or data during page-processing-PS/SQL

    Greetings!
    On my page I have a custom report (from 2 tables) and a small form-field, that adds and edits data in the report. After generating the form with the wizard I added an extra item, to store the id from one of the tables from the report data.
    Now, on submit a calculation should take place, that updates data according user input with a procedure in Page-Prosseses:
    declare a number;
    begin
    case :PLATZ
    when 1 then a:=100;
    when 2 then a:= 50;
    else a:=25;
    end case;
    update TBL_MITGLIEDER set TURNIERPUNKTE = TURNIERPUNKTE + a
    where ID_MITGL = :P14_ID_MITGL;
    end;
    :PLATZ is user selected (1,2,3), :P14_ID_MITGL stores the reference to TBL_MITGLIEDER (and shows the change, when I select another record)
    As I understand, that process should also run, when I submit a chance, but nothing happens then.
    But when I try to save a new record (which worked without any problems before adding that process), I get this error message:
    ORA-06550: line 1, column 64: PL/SQL: ORA-00957: duplicate column name ORA-06550: line 1, column 7: PL/SQL: SQL Statement ignored
         Error      Unable to process row of table TBL_TURNIERSIEGER.
    Then, when I go back into the app-builder and try to run the page again, I get this message:
    ORA-01403: no data found
         Error      Unable to fetch row.
    I am not sure, if you guys have all the information you need, to know whats going on. Maybe this has to do with session-id and the whay, items are updated. I hope you can help me.
    Thanks, best regards,
    tobi

    First can you please post all log file errors
    >> I can't really give you a solution or specific recommendation since I did not saw this error yet myself, but on your own risk you can try:
    1. You may try to just register 'dts.dll' using regsvr32.exe, but this error may indicate a bigger problem with setup.
    If you are running SQL Server 64bit then try running this at the command prompt: %windir%\syswow64\regsvr32 "%ProgramFiles(x86)%\Microsoft SQL Server\90\dts\binn\dts.dll"
    2. You can try reinstall from start (In this case you have to make sure that you un-install all)
    [Personal Site] [Blog] [Facebook]

  • Item descriptions update on Master Data

    Hi there,
    Item descriptions update on master data does not get read into existing sales orders and subsequently when delivery dockets and invoice are generated, they are all not updated. Could the SAP programmer analysts please fix this bug? thanks.
    Similarly if item's GL account is set by item group and the item group is changed after an item is processed on sales order, the change in GL posting is not reflected when invoice is subsequently processed. Please also fix this bug, thanks.

    Hi Amy,
    for both  issue nothing to do from SAP MDM side, You need to take help of SAP Technical Consultant(Programmer) which analyst the problem and fix it for e.g. SAP Notes updation for program or assign/change SAP standard program for  message type  etc.
    Thanks,
    Jignesh Patel

  • Problem regarding item level data in CRMD_ORDER

    i have created a sales order in CRMD_ORDER and entered all the data for header and item . i have given required delievery date for both item and header different , but when we save the order a BADI is trigerred which will update the data to R/3 but still only header required delievery date is updated not the item level date can you provide any solution for this problem?
    another thing is can i know where does the item level data is store ie: date, quantity etc.

    Hello,
    You are posting to the SAP CRM 2007 forum so we assume you are using CRM 2007. In CRM 2007 the GUI is no longer supported and doesn't work as expected since SAP did not update the business logic in it.
    So, if you want to test your process and be 100% sure that there is a problem, use the WebUI for your tests.
    All item data is stored in CRMD_ORDERADM_I. If you want to find a date (of an item date profile) stored in an item you have to pass some tables however.
    CRMD_ORDERADM_I->CRMD_LINK->SCAPPTSEG.
    Reward points if useful!
    Regards,
    Joost

  • Problem getting correct data from MS Access after doing an Update

    Hi all,
    I have a problem getting correct data after doing an update. This is the scenario
    I am selecting some(Eg: All records where Column X = �7� ) records and update a column with a particular value (SET Column X = �c� ) in all these records by going through a while loop. In the while loop I add these records to a vector too, and pass it as the return value.
    After getting this return value I go through a for loop and get each record one by one from the DB and check if my previous update has actually happened. Since No errors were caught while updating DB, I assume all records are updated properly but my record set shows one after another as if it has not been updated. But if I open the DB it is actually updated.
    This does not happen to all records, always it shows like this
    1st record     Mode = �c�
    2nd record     Mode = �7�
    3st record     Mode = �c�
    4nd record     Mode = �7�
    9th record     Mode = �c�
    10th record     Mode = �7�
    I am relatively new to java and this is someone elses code that I have to modify,So I am not sure if there some thing wrong in the code too
    //Here is the method that gets records and call to update and add to vector
    public static Vector getCanceledWorkOrders() throws CSDDBException{
    //Variable declaration
      try {
        objDBConn = DBHandler.getCSDBCon();
        strSQL  = "SELECT bal bla WHERE [Detailed Mode])=?)";
        objStmt = objDBConn.prepareStatement(strSQL);   
        objStmt.setString(1, '7');
        objWOPRs = objStmt.executeQuery();
        while (objWOPRs.next()) {
         //Add elements to a vector by getting from result set
          //updating each record as PROCESSING_CANCELLED_WO(c)
          iRetVal = WorkOrderDetailingPolicy.updateRecordStatus(objPWODP.iWorkOrderNumber, objPWODP.strPersonInformed, EMSConstants.PROCESSING_CANCELLED_WO);
          if (iRetVal == -1) {
            throw new NewException("Updating failed");
      catch (Exception e) {
        vecWONumbers = null;
        throw new CSDDBException(e.getMessage());
      }finally{
        try {
          objWOPRs.close();
          objStmt.close();
          DBHandler.releaseCSDBCon(objDBConn);
        catch (Exception ex) {}
      //return vector
    //here is the code that actually updates the records
    public static int updateRecordStatus(int iWONumber, String strPerInformed , String strStatus) throws CSDDBException{
       PreparedStatement objStmt = null;
       Connection objDBConn  = null;
       String strSQL = null;
       int iRetVal = -1;
       try{
         objDBConn  = DBHandler.getCSDBCon();
         objDBConn.setAutoCommit(false);
         strSQL = "UPDATE Table SET [Detailed Mode] = ? WHERE bla bla";
         objStmt = objDBConn.prepareStatement(strSQL);
         objStmt.setString(1, strStatus);    
         objStmt.execute();
         objDBConn.commit();
         iRetVal = 1;
       }catch(Exception e){
         iRetVal = -1;
       }finally{
         try{
           objStmt.close();
           DBHandler.releaseCSDBCon(objDBConn);
         }catch(Exception ex){}
       return iRetVal;
    //Here is the code that call the records again
      public static WorkOrderDetailingPolicy getWorkOrders(int iWorkOrderNo) throws CSDDBException{
        Connection objDBConn = null;
        PreparedStatement objStmt = null;
        ResultSet objWOPRs = null;
        WorkOrderDetailingPolicy objPWODP = null;
        String strSQL = null;
        try {
          objDBConn = DBHandler.getCSDBCon();    
          strSQL = "SELECT * FROM [Work Order Detailing] WHERE [Work Order No] = ?";
          objStmt = objDBConn.prepareStatement(strSQL);
          objStmt.setInt(1, iWorkOrderNo);
           objWOPRs = objStmt.executeQuery();
          if (objWOPRs.next()) {
            objPWODP = new WorkOrderDetailingPolicy();
            objPWODP.iWorkOrderNumber = objWOPRs.getInt("Work Order No");
            //......Get Record values
        catch (Exception e) {
          objPWODP = null;
          throw new CSDDBException(e.getMessage());
        }finally{
          try {
            objWOPRs.close();
            objStmt.close();
            DBHandler.releaseCSDBCon(objDBConn);
          catch (Exception ex) {}
        return objPWODP;
      }

    Hello,
    Can you put an example of your problem online?
    Are you sure you're not having problems with case sensitive data?
    Thanks,
    Dimitri

  • Problem with Java Dates and UPDATE for SQL2000

    I am having problems with the date formats for Java. I am trying to put the current date time into a SQL table, here it the code I am using:
    var Today = new Date()
    var conn = Server.CreateObject( "ADODB.Connection" )
    conn.Open( "Provider=SQLOLEDB;Server=(local);Database=BillTracking;UID=sa;PWD=;")
    var sql = "UPDATE BillAssignments SET DatePosted = " + Today + " WHERE AssignmentID = '" + Request.QueryString("AssignmentID") + "'"
    var rs = conn.execute(sql)
    I keep getting different errors and I have been unable to find a solution yet. I know that I need to change the date format from the Java standard to the one that SQL likes.
    Help....
    Norm...

    Please tell us where the Java part of this comes in. I see that you are using JavaScript to load up data via an ADO connection (presumably on an IIS platform) - but I do not see where you are using Java
    Lee

  • The action could not be completed because of a conflict with the original item. The conflict may have occurred when an existing item was updated on another computer or device. Open the item again and try making your changes. If the problem continues, cont

    I have a user on an iMac 10.6 connected to our domain.  She uses Outlook web access for email on our exchange server.  Last week she received the following message which is randomly preventing her from sending emails.  She claims no attachment was involved in the original email when this all started.  I have not been able to look at her account as she is out of the office but maybe someone else dealt with this issue.  I realize this may not be Mac related but thought I'd give it a try.  She did say it occurred once over two days while working on a PC but it continued over the past weekend.
    If an internal user tries to send a message with infected attachment using Outlook Web Access, it may report the following error message: The action could not be completed because of a conflict with the original item. The conflict may have occurred when an existing item was updated on another computer or device. Open the item again and try making your changes. If the problem continues, contact technical support for your organization.
    This is because F-Secure Anti-Virus for Microsoft Exchange has detected a virus in the attachment. If the user tries to send the message again, the message will be sent but without the attachment. At the same time a blank message with an attachment named "Attachment_information.txt" will remain in the user's Drafts folder. The "Attachment_information.txt" will contain information about the virus detected in the message.

    PS - have found other posts indicating that clips smaller than 2s or sometimes 5s, or "short files" can cause this. Modern style editing often uses short takes ! Good grief I cannot believe Apple. Well I deleted a half a dozen short sections and can export, but now of course the video is a ruined piiece of junk and I need to re-do the whole thing, the sound etc. which is basically taking as much time as the original. And each time I re-do it I risk again this lovely error -50 and again trying to figure out what thing bugs it via trial and error instead of a REASONABLE ERROR MESSAGE POINTING TO THE CLIP IT CAN'T PROCESS. What a mess. I HATE this iMovie application - full of BUGS BUGS BUGS which Apple will not fix obviously, since I had this product for a few years and see just hundreds of hits on Google about this error with disappointed users. Such junk I cannot believe I paid money for it and Apple does not support it with fixes !!!
    If anyone knows of a GOOD reasonably priced video editing program NOT from APPLE I am still looking for suggestions. I want to do more video in future, but obviously NOT with iMovie !!!

  • Updating product revenue close date based off opportunity close date

    We do not use the product revenue close date, only the opportunity close date. We need to get the fiscal month of the opportunity close date but we have several reports the need to use the opportunity product history area and that does not contain the fiscal month for the opportunity. If we did a combined report, we cannot offer the user any prompts.
    Does anyone know how to get the opportunity close date fiscal month from the opportunity products area? Is there a way to update the product revenue close date when the opportunity close date it updated?
    Thanks

    Hi David,
    In the universe you describe you have the opportunity 'Close Date'. Use a 'case-when' expression to create the 'Fiscal Month' you need.
    Other than that you can use the JoinFieldValue function in the application to retrieve the opty close date, but that will require you to update product revenue for it to trigger which probably won't work for you.
    Good luck.

  • I bought new i phone 5 3 days back, after that asked for new update which is 6.1.4, after updating my iphone i am not able to use cellular data services. I called up data provider, they says its the problem with new software update. There is no option add

    I bought new i phone 5 3 days back, after that asked for new update which is 6.1.4, after updating my iphone i am not able to use cellular data services. I called up data provider, they says its the problem with new software update. There is no option add APN. Now when i switch to safari its showing you are not subscribed for cellular data. But I am able to use data on other phone.
    Will you please help me in this regard?
    Another issue, since i bought my new iphone there is dust inside back main camera.
    Your advises are highly appreciated.

    Hey Shaiju isac,
    I'd take a look at the following article, it'll guide you though steps to you troubleshoot cellular data issues on your iPhone:
    iPhone: Troubleshooting a cellular data connection
    http://support.apple.com/kb/ts3780
    Cheers,
    David

  • To update the po line item data into sap thru bdc

    Hi Experts,
    My requirement is to create a bdc program .  get the po line item data from the file and will update in sap thru bdc .so please help on source code how to create .
    Thanks advance,
    Prashanth p.

    Hi,
    Check this link,
    /message/5215197#5215197 [original link is broken]
    Regards,
    Bhanu

  • Problem in sap script for Item data

    Hi Guys ,
    Although I am working in ABAP for last 1 year but I am new to SAP script , This is first time I am doing this -
    I am creating excise invoice profarma and able to print all that data except J_1IEXCDTL ( Item data ) that I have to display in loop ,
    I am using
    LOOP AT ITAB_J_1IEXCDTL.
      CALL FUNCTION 'WRITE_FORM'
           EXPORTING
                ELEMENT = 'ITEM_VALUES'
                WINDOW  = 'MAIN'
           EXCEPTIONS
                ELEMENT = 1
                WINDOW  = 2.
    ENDLOOP.
    My problem is that this is working fine for 1 record but if there are more than 1 record in ITAB_J_1IEXCDTL. , it is showing only first record ,
    Other thing i want to know what is connection of element between Driver program and sap script , Can we give any name to element and it doesnt make any impact on Sap script
    i have done same in my program ,
    Thanks in advance
    Amit

    my problem is solved now ,
    Thanks

  • Problem in data update to BW

    Hi All,
    We are facing a very peculiar problem while data updating in BW. Data for GL, AR gets updated evryday twice through process chain. But sometimes even after normal load data does not gets updated properly and changed data comes after 2-3 loads though it sould have come before. Can you pls provide possible suggestion for this behaviour.
    Thanks in advance,
    Sananda

    Hi Sananda,
    Please got through the below article
    http://www.sdn.sap.com/irj/scn/go/portal/prtroot/docs/library/uuid/a00ae8f2-03ad-2d10-71b7-962915661a93?quicklink=index&overridelayout=true
    and can you tell me the type of delta update you are using
    This should be because of your delta update mode
    Hope this helps
    Regards,
    Venkatesh

Maybe you are looking for