Problem in updating PA0028-SBJ fields

Hello Experts,
       I have a requirement where i need to check for the values of SBJ01 to SBJ30 and based on the values we have to update correspondign WTF fields.
I tried with Do varying but got lost some where and my code is not working.  pl. help me with a piece of code ASAP. 
Thanks
RK

Hi,
g_sbj01 is the varible which the value and p0028 is the internal table type p0028.
check the below code for better understanding..
Example...
  rp_provide_from_last p0028 '0001' g_begda g_endda.
  IF pnp-sw-found = '1'.
    DO 30 TIMES VARYING g_SBJ01 from p0028-SBJ01 NEXT p0028-SBJ02
                VARYING g_wtf01 from p0028-wtf01 NEXT p0028-wtf02.
      CASE g_SBJ01.
        when '08'.
          i_final_line-WTFLD = g_wtf01.
        when '09'.
          CONCATENATE i_final_line-WTFLD g_wtf01
                INTO i_final_line-WTFLD.
    ENDDO. 
  ENDIF.
OR
loop at p0028.
    DO 30 TIMES VARYING g_SBJ01 from p0028-SBJ01 NEXT p0028-SBJ02
                VARYING g_wtf01 from p0028-wtf01 NEXT p0028-wtf02.
      CASE g_SBJ01.
        when '08'.
          i_final_line-WTFLD = g_wtf01.
        when '09'.
          CONCATENATE i_final_line-WTFLD g_wtf01
                INTO i_final_line-WTFLD.
    ENDDO. 
ENDLOOp.

Similar Messages

  • Problem with update of BLOB field in a table with compound primary key

    Hi,
    I've been developing an application in Application Express 3.1.2.00.02 that includes processing of BLOB data in one of the tables (ZPRAVA). Unfortunately, I've come across a strange behaviour when I tried to update value in a BLOB field for an existing record via a DML form process. Insert of a new record including the BLOB value is OK (the binary file uploads upon submiting the form without any problems). I haven't changed the DML process in any way. The form update process used to work perfectly before I'd included the BLOB field. Since than, I keep on getting this error when trying to update the BLOB field:
    ORA-20505: Error in DML: p_rowid=3, p_alt_rowid=ID, p_rowid2=CZ000001, p_alt_rowid2=PR_ID. ORA-01008: not all variables bound
    Unable to process row of table ZPRAVA.
    OK
    Some time ago, I've already created another application where I used similar form that operated on a BLOB field without problems. The only, but maybe very important, difference between both the cases is that the first sucessfull one is based on a table with a standard one-column primary key whereas the second (problematic one) uses a table with compound (composite) two-column PK (two varchar2 fields: ID, PR_ID).
    In both cases, I've followed this tutorial: [http://www.oracle.com/technology/obe/apex/apex31nf/apex31blob.htm]).
    Can anybody confirm my suspicion that Automatic Row Processing (DML) can be used for updating BLOB fields within tables with only single-column primary keys?
    Thanks in advance.
    Zdenek

    Is there a chance that the bug will be included in the next patch?No, this fix will be in the next full version, 3.2.
    Scott

  • Problem in updating VEKP-LTEXT field

    Hi,
    I need to update VEKP-LTEXT field for a vehicle(HU), i got a FM LXYRD_HU_UPDATE to update this, but the only problem is i am not able to clear that field(VEKP-LTEXT). Insert and modify is working fine except clearing the text field(VEKP-LTEXT).
    Please help me....

    in the function module you provided 'LXYRD_HU_UPDATE' in order to clear the field VEKP-LTEXT, <br />
    you do the declartion and pass this value LTEXT to the internal table and use the command 'REFRESH' to clear the text in the 'LTEXT' each time it passes in the loop
    REFRESH ITAB. " ITAB is the internal table which you have to declare with the field LTEXT'

  • Problem to update VBAP-ERLRE field in a standard table----Its urgent

    Hi friends,
       ERLRE: Completion Rule
      I need to create custom utility program to update ERLRE field(already it was set with B for thos specific orders,i need to upadte with null value for those) in production for specific orders.I checked FM: sd_salesdocument_change, but ITEM_IN STRUCTURE  BAPISDITM ,ITEM_INX STRUCTURE  BAPISDITMX OPTIONAL
    those two structures not contain ERLRE field. Only  ITEMS_EX STRUCTURE  BAPISDIT OPTIONAL contain ERLRE field.
    It does not have any x structure corresponding it.
    Please help me how to update that field? Is there any other solution for that?
    Thanks,
    Monica

    Hi Rob,
    I am doing the same way what you told, but its not updation data in table. Can you please check my code what i had done.
    DATA: header_in     LIKE bapisdhd1,
          header_in_x   LIKE bapisdhd1x,
          item_in       LIKE bapisditm  OCCURS 0 WITH HEADER LINE,
          item_in_x     LIKE bapisditmx OCCURS 0 WITH HEADER LINE,
          return        LIKE bapiret2   OCCURS 0 WITH HEADER LINE,
          ITEMS_EX      LIKE BAPISDIT OCCURS 0 with header line.
    DATA: rec_ok TYPE char1.
    DATA: t_vbak LIKE vbak OCCURS 0 WITH HEADER LINE.
    DATA: t_vbap LIKE vbap OCCURS 0 WITH HEADER LINE.
    DATA: icnt TYPE i,
          gcnt(1) TYPE c,
          g_ordertype LIKE vbak-auart,
          c_zso(3) TYPE c VALUE 'ZSO'.  " sales order type
    SELECT vbeln FROM vbak INTO  corresponding fields of  TABLE t_vbak
                           WHERE vbeln = '0090000141'.
    CHECK sy-subrc = 0.
    LOOP AT t_vbak.
    Ini structures
      CLEAR header_in.
      CLEAR header_in_x.
    Ini tables
      CLEAR   item_in.
      REFRESH item_in.
      CLEAR   item_in_x.
      REFRESH item_in_x.
      CLEAR   items_ex.
      REFRESH items_ex.
      CLEAR   return.
      REFRESH return.
      SELECT vbeln posnr  INTO CORRESPONDING FIELDS OF TABLE t_vbap
                                        FROM vbap
                                        WHERE vbeln = t_vbak-vbeln AND posnr = '000100'.
      CHECK sy-subrc = 0.
    Set header data
      header_in_x-updateflag = 'U'.
    Set line item data
      LOOP AT t_vbap WHERE vbeln = t_vbak-vbeln.
        items_ex-operation = '005'.
        items_ex-doc_number = t_vbap-vbeln.
        items_ex-itm_number = t_vbap-posnr.
        items_ex-updat_flag = 'X'.
        items_ex-end_rule = 'C'.
        APPEND items_ex.
        CLEAR items_ex.
      ENDLOOP.
    Disable dialog
      CALL FUNCTION 'DIALOG_SET_NO_DIALOG'.
    Run BAPI
      CALL FUNCTION 'SD_SALESDOCUMENT_CHANGE'
        EXPORTING
          salesdocument     = t_vbak-vbeln
          order_header_in   = header_in
          order_header_inx  = header_in_x
          behave_when_error = 'P'
          call_from_bapi    = 'X'
        TABLES
          return            = return
         item_in           = item_in
         item_inx          = item_in_x
          items_ex          = items_ex.
    Check for errors
      IF sy-subrc = 0.
        LOOP AT return.
          IF return-type = 'E'.
            rec_ok = 'N'.
            EXIT.
          ENDIF.
           IF return-type = 'S'.
            write:/ 'success'.
          ENDIF.
        ENDLOOP.
        IF rec_ok  = 'N'.
          ROLLBACK WORK.
              ELSE.
          COMMIT WORK AND WAIT.
          WRITE:/ 'Success_flag?'.
        ENDIF.
      ENDIF.
    ENDLOOP.

  • Problem in updating MSEG-MENGE field using MB_CF001

    Hi,
    Does anyone have any idea if the user exit MB_CF001 , EXIT_SAPLMBMB_001 can be used to update MSEG table.
    I tried updating it many many times... but all in vein..
    I am using ML81N(SES Entry Sheets) transaction to update MSEG table.
    All alternate ideas are welcome.
    Thanks,
    Harmeet.

    no one answered, but I figured out.. this exit cannot be used to update any field..

  • Problem in Updating KNA1 table fields.

    Hi,
       I have small issue , i need to block the customer while creating im using BADI(ADDRESS_UPDATE) to block the customer created.In the BADI im trying to update few fields of KNA1 table using UPDATE statement.
    Like this...
        WA_KNA1-SPERR = 'X'.
        WA_KNA1-CASSD = 'X'.
        WA_KNA1-AUFSD = '01'.
        WA_KNA1-FAKSD = '01'.
        WA_KNA1-LIFSD = '01'.
        UPDATE KNA1 SET SPERR = WA_KNA1-SPERR
                                        AUFSD = WA_KNA1-AUFSD
                                         LIFSD = WA_KNA1-LIFSD
                                       FAKSD = WA_KNA1-FAKSD
                                        CASSD  = WA_KNA1-CASSD
                    WHERE KUNNR = W_KUNNR.
    when this statement excutes it is updating
                                                                         1) SPERR
                                                                         2) AUFSD this two field remaining 3 fields it is not updating
    Can anyone pls let me know the reason .
    thanks in Adv.

    see note 1469543
    it is not possible to update kna1 directly, you must create a bim
    oops sorry see that you're question is it inside a badi and not bapi
    kind regards
    arthur
    Edited by: A. de Smidt on Jul 20, 2010 10:45 AM

  • Problem with ojdbc14.jar (oracle10g Rel. 2 driver) in updating a BLOB field

    Hello All,
    Our web application uses oracle10g Release 2 jdbc driver with websphere 5.1.1.4 and oracle 9i. When it tries to update a BLOB field in the database updation is successful but it is updating that field with a null value. So rest of our application fails as this value is becoming null. We use an entity bean to update this table and websphere uses a prepared statement to update this table. Just before setting this BLOB field using setBinaryStream() on prepared statement I am printing to see whether it is null or not as shown in the code snippet below. And it is printing it correctly as non null. But after execution of the prepared statement some how the value stored in database is null.
    Is this a known issue with this driver? Does any one know work around or a solution to this? We have 3 BLOB fields in that table. Is that a problem? If we separate these BLOB fields into separate tables will the problem be solved? Any input on this is very much appreciated.
    // For column ORIGINAL_CONTENT
    byte[] tempbyteArray;
    tempbyteArray=(byte[])inputRecord.get(25);
    if (tempbyteArray == null) {
    System.out.println("DqPageBeanFunctionSet_f9c724af: tempbyteArray NULLLLLLL");
    } else {
    System.out.println("DqPageBeanFunctionSet_f9c724af: orig tempbyteArray length: " + tempbyteArray.length);
    if(tempbyteArray != null) {
    pstmt.setBinaryStream(25,new java.io.ByteArrayInputStream(tempbyteArray),tempbyteArray.length);
    else pstmt.setNull(25,java.sql.Types.BLOB);
    Thanks & Regards,
    -Sunitha

    I have similar problem and I solved it using ojdbc14.jar oracle9i version.
    try...

  • Problem in updating field in databse

    Hi experts
    I have internal table i_lips I need to update a single field  in lips table on certain condtions
    I have tried this code but performance is too low ..
    Loop at i_lips.
    If  i_lips-kostl NE i_lips-ikostl.
    Update lips ser kostl = i_lips-ikostl  where vbeln  =  i_lips-vbeln.
    Endif.
    Endloop.

    Hi,
    Make sure all the remaining values are maintained properly, & take care for the necessary precations for updating table directly,
    Also try search f1 help on update command, & check if your updating it correctly,
    you can try modify statement as well.
    -Dileep .C

  • BLOBDestination. Problem in updating BLOB field

    hi,
    Im trying to customize BLOBDestination package to update a BLOB field. So I modified the method insertBLOB replacing the insert statement with this
    stmtStr = "UPDATE " + " " + tab + " " + "SET "+ "'" blobCol "'=" + "'" + "empty_blob()" + "'"+ "WHERE " + "'"+keyCol+"'=" + "'" + key+ "'" ;
    stmt.executeUpdate(stmtStr);
    calling BLOBDestination from form I got this stmtStr:
    UPDATE MYTABLE SET blob_field=empty_blob() WHERE col1 = 'val1' (copied from OC4J_BI_Forms log file)
    but the execution returns this error:
    REP-50125: blobdestination : exception: java.sql.SQLException: ORA-00933: SQL command not properly ended
    I can affirm that the statement works if executed from TOAD or SQL*Plus
    what's wrong?

    It depends on how you have your table control set up.  When you say that you are updating the table control field, are you updating the value of the field wherever the table control data is being pulled from (I.e. the original table)?  Or are you updating the value in the internal table that is part of the table control definition (I.e. the field shown within the table control if you look at the screen layout)?  Make sure that if you are changing the data in the original table that you then also update the actual table control fields as well.  Also, are you making your changes in the PBO module before the screen is ever displayed?  You may need to use a MODIFY SCREEN statement after you make your changes, depending on when your code is called.  I hope this helps.
    - April King

  • Another problem with updating in ms access

    Hello there,
    Me too has a problem with the update statement and ms access (using 2003).
    I've read many other problems, but a way to the solution that worked for I didn't found :S
    The strange thing with my problem is that i'm able to update integer fields in the database, but not varchar/text fields.
    I'm not getting any exception back, the database is closed (i'm very sure), so HELP! :)
    I'll show you the code i'm connecting with the database:
    public void openDatabaseConnection() {
            // Eerst controleren of de DatabaseDriver wel aanwezig is.
            try {
                Class.forName("sun.jdbc.odbc.JdbcOdbcDriver");
            catch (Exception e) {
                System.out.println("Looking for Class: " + e.toString());
            // Nu kan de connectie met de database opgezet worden.       
            try {
                theDatabaseConnection = DriverManager.getConnection("jdbc:odbc:Shawa","","ShaBaMa");           
            catch (SQLException ex) {
                System.out.println("openDatabaseConnection: SQLException: " + ex.getMessage());
                System.out.println("openDatabaseConnection: SQLState: " + ex.getSQLState());
                System.out.println("openDatabaseConnection: VendorError: " + ex.getErrorCode());        
        }The code for updating an integer field (wich is working!) is like this:
        public Customer cashCustomer(Customer aCustomer){
            PreparedStatement pstmt;
            ResultSet result;
            try{
                openDatabaseConnection();
                pstmt = theDatabaseConnection.prepareStatement("UPDATE customer SET aantal_bier = aantal_bier + ?, aantal_fris = aantal_fris + ? WHERE id=?");
                pstmt.setInt(1, aCustomer.getCashBeer());
                pstmt.setInt(2, aCustomer.getCashSoda());
                pstmt.setInt(3, aCustomer.getId());
                theDatabaseConnection.setAutoCommit(false);
                pstmt.executeUpdate();
                theDatabaseConnection.commit();
                pstmt.close();
                theDatabaseConnection.close();
            catch (SQLException eSql){
                System.out.println("Cash Customer: " + eSql.toString());
                System.out.println("Cash Customer: SQLException: " + eSql.getMessage());
                System.out.println("Cash Customer: SQLState: " + eSql.getSQLState());
                System.out.println("Cash Customer: VendorError: " + eSql.getErrorCode());
            return aCustomer;
        }Now the code for updating Varchar/text fields (wich is not working):
        public Customer editCustomer(Customer aCustomer){
            PreparedStatement pstmt;
            ResultSet result;
            try{
                openDatabaseConnection();
                pstmt = theDatabaseConnection.prepareStatement("UPDATE customer SET name=? , lastname=?, onderdeel=?, aantal_bier=?, aantal_fris=?, op_kaart=? WHERE id=?");
                pstmt.setString(1, aCustomer.getName());
                pstmt.setString(2, aCustomer.getLastname());
                pstmt.setString(3, aCustomer.getSection());
                pstmt.setInt(4, aCustomer.getBeer());
                pstmt.setInt(5, aCustomer.getSoda());
                pstmt.setInt(6, aCustomer.getId());
                pstmt.setString(7, aCustomer.getAddCash());
                theDatabaseConnection.setAutoCommit(false);
                pstmt.executeUpdate();
                theDatabaseConnection.commit();
                pstmt.close();
                theDatabaseConnection.close();
            catch (SQLException eSql){
                System.out.println("Updating Customer: " + eSql.toString());
                System.out.println("Updating Customer: SQLException: " + eSql.getMessage());
                System.out.println("Updating Customer: SQLState: " + eSql.getSQLState());
                System.out.println("Updating Customer: VendorError: " + eSql.getErrorCode());
            return aCustomer;
        }I can add and delete from the database. The thing with the ' ' didn't work for me too.
    Anybody a solution for me??? plz plz plz!

    You are updating zero records. Because you are filling in the parameter ofWHERE id=?with this code:pstmt.setString(7, aCustomer.getAddCash());The executeUpdate() method returns the number of records affected, if you wish to check that.

  • Issue in Updating Customer specific fields in WBS using BAPI_BUS2054_CREATE_MULTI

    Hi Experts,
    I am able to create the WBS element using BAPI_BUS2054_CREATE_MULTI.But the issue is i am not able to update customer specific fields even after passing the fields as per specification in Function module documentation. I have also created an implementation of BADI  as per below specification in FM documentation:
    Procedure for Filling Standard Enhancements
    Before you call the BAPI for each object that is to be created or changed,
    for which you want to enter customer-specific table enhancement fields, add a
    data record to the container ExtensionIn:
    STRUCTURE:    Name of the corresponding help structure
    VALUEPART1:   Key of the object + start of the data part
    VALUEPART2-4: If required, the continuation of the data part
    VALUPART1 to VALUPART4 are therefore filled consecutively, first with the
    keys that identify the table rows and then with the values of the
    customer-specific fields. By structuring the container in this way, it is
    possible to transfer its content with one MOVE command to the structure of the
    BAPI table extension.
    Note that when objects are changed, all fields of the enhancements are
    overwritten (as opposed to the standard fields, where only those fields for
    which the respective update indicator is set are changed). Therefore, even if
    you only want to change one field, all the fields that you transfer in
    ExtensionIn must be filled.
    Checks and Further Processing
    Using the methods ...CREATE_EXIT1 or. ...CHANGE_EXIT1 of the BAdI
    BAPIEXT_BUS2001, BAPIEXT_BUS2002, and BAPIEXT_BUS2054, you can check the entered
    values (and/or carry out other checks).
    In the BAdI's second method, you can program that the data transferred to the
    BAPI is processed further (if you only want to transfer the fields of the CI
    includes, no more action is required here).
    But still i am unable to update fields though i am able to create WBS with rest of the fields except  custom fields.
    I am using attached code to achieve this.Do we need to code anything inside method create_exit1 or create_exit2 implementation for BADI or
    Please help on priority

    Hi Rahul,
    First observation from your code is that i could not find the assignment for the field
    GWA_WBS_EXTIN-STRUCTURE. I hope you are not filling this field, that could be one reason for failure. Try to do it and let us know if you still have the problem.
    Br..
    Dwaraka

  • How to update the Customer field value of PO Item under the Delivery Address Tab?

    Hi Friends,
         i tried to update the Customer field Using Bapi_PO_change.I passed the PO Order no,POADDRDELIVERY data with Item no,Adrees no,Customer no.But i am getting no data changed message from return table.I attached the screen shots.So please suggest me the helpful information for resoving this issue.
    Thanks,
    Dinesh

    Thank you friends,
                My Problem was resolved.In my case i have passed the customer value in BAPI_PO_CHANGE POITEM Table with updated customer value.
    Thanks,
    Dinesh

  • Problem in UPDATE statement In Multiple Record Block

    Hi Friends,
    I have problem in update Statement for updating the record in multiple record data Block.
    I have two data Block the master block is single Record block and the 2nd data block is Multiple Record data Block.
    I am inserting the fields like category,and post_no for partiular job in single data block
    Now in second Multiple Record Data Block,i am inserting the multiple record for above fileds like no. of employees work in the position
    There is no problem in INSERT Statement as it is inerting all record But whenever i want to update particular Record (in Multiple Block) of employee for that category and Post_no
    then its updating all the record.
    my code is Bellow,
    IF v_count 0 THEN
    LOOP
    IF :SYSTEM.last_record 'TRUE' THEN
    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;
    IF SQL%NOTFOUND THEN
    INSERT INTO post_history(post_no,roster_no,category,idcode,joining_post_dt,leaving_post_dt,entry_gp_stage)
    VALUES(g_post_no, g_roster_no, g_category, :POST_HISTORY_MULTIPLE.idcode, :POST_HISTORY_MULTIPLE.joining_post_dt,
    :POST_HISTORY_MULTIPLE.leaving_post_dt,:POST_HISTORY_MULTIPLE.entry_gp_stage);
    END IF;
    next_record;
    ELSIF :SYSTEM.last_record = 'TRUE' THEN
    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;
    IF SQL%NOTFOUND THEN
    INSERT INTO post_history(post_no,roster_no,category,idcode,joining_post_dt,leaving_post_dt,entry_gp_stage)
    VALUES (g_post_no,g_roster_no,g_category,:POST_HISTORY_MULTIPLE.idcode,
    :POST_HISTORY_MULTIPLE.joining_post_dt,:POST_HISTORY_MULTIPLE.leaving_post_dt,:POST_HISTORY_MULTIPLE.entry_gp_stage);
    END IF;
    EXIT;
    END IF;
    END LOOP;
    SET_ALERT_PROPERTY('user_alert',ALERT_MESSAGE_TEXT, 'Record Updated successfuly' );
    v_button_no := SHOW_ALERT('user_alert');
    FORMS_DDL('COMMIT');
    CLEAR_FORM(no_validate);
    Please Guide me
    Thanks in advence

    As you do a loop over all the records in the block, of course every record is updated.
    Also, what you do is not the way is intended to be used. In general, you base a block on a table,then there is no need at all for writing INSERT's or UPDATE's. Forms also know's then, which records to be updated and which not.

  • Problem In Update Statement In Multiple Record Data Block

    Hi Friends,
    I have problem in update Statement for updating the record in multiple record data Block.
    I have two data Block the master block is single Record block and the 2nd data block is Multiple Record data Block.
    I am inserting the fields like category,and post_no for partiular job in single data block
    Now in second Multiple Record Data Block,i am inserting the multiple record for above fileds like no. of employees work in the position
    There is no problem in INSERT Statement as it is inerting all record But whenever i want to update particular Record (in Multiple Block) of employee for that category and Post_no
    then its updating all the record.
    my code is Bellow,
    IF v_count <> 0 THEN
    LOOP
    IF :SYSTEM.last_record <> 'TRUE' THEN
    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;
    IF SQL%NOTFOUND THEN
    INSERT INTO post_history(post_no,roster_no,category,idcode,joining_post_dt,leaving_post_dt,entry_gp_stage)
    VALUES(g_post_no, g_roster_no, g_category, :POST_HISTORY_MULTIPLE.idcode, :POST_HISTORY_MULTIPLE.joining_post_dt,
    :POST_HISTORY_MULTIPLE.leaving_post_dt,:POST_HISTORY_MULTIPLE.entry_gp_stage);
    END IF;
    next_record;
    ELSIF :SYSTEM.last_record = 'TRUE' THEN
    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;
    IF SQL%NOTFOUND THEN
    INSERT INTO post_history(post_no,roster_no,category,idcode,joining_post_dt,leaving_post_dt,entry_gp_stage)
         VALUES (g_post_no,g_roster_no,g_category,:POST_HISTORY_MULTIPLE.idcode,
              :POST_HISTORY_MULTIPLE.joining_post_dt,:POST_HISTORY_MULTIPLE.leaving_post_dt,:POST_HISTORY_MULTIPLE.entry_gp_stage);
    END IF;
    EXIT;
    END IF;
    END LOOP;
    SET_ALERT_PROPERTY('user_alert',ALERT_MESSAGE_TEXT, 'Record Updated successfuly' );
    v_button_no := SHOW_ALERT('user_alert');
    FORMS_DDL('COMMIT');
    CLEAR_FORM(no_validate);
    Please Guide me
    Thanks in advence

    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;
    UPDATE post_history
    SET idcode = :POST_HISTORY_MULTIPLE.idcode,
    joining_post_dt = :POST_HISTORY_MULTIPLE.joining_post_dt,
    leaving_post_dt = :POST_HISTORY_MULTIPLE.leaving_post_dt,
    entry_gp_stage = :POST_HISTORY_MULTIPLE.entry_gp_stage
    WHERE post_no = :POST_HISTORY_SINGLE.post_no
    AND category = :POST_HISTORY_SINGLE.category
    AND roster_no = :POST_HISTORY_SINGLE.roster_no;
    AND idcode = :POST_HISTORY_MULTIPLE.idcode;These update statements are without where clause, so it will update all records.
    If it is specific to oracle forms then u may get better help at Forms section.

  • Lock when trying to update a Z-field in MARD

    Hi,
    I have a Z-field in an append to MARD. In MIGO we create an output idoc (a custom made Z-idoc) and in the function module processing the idoc I want to update my Z-field in MARD. The update in MARD are made with a bapi called BAPI_MATERIAL_SAVEDATA.
    Pseudocoding of the function module which are processing the idoc:
    Get material document into bapi structures
    loop items.
       perform get_some_more stuff
       perform update_mard.
    endloop.
    form update_mard.
        do some stuff
        call method class=>update_mard
        loop at error messages.
             Give a message
       endloop.
        call function BAPI_TRANSACTION_COMMIT.
    endform.
    in the update_mard-method I fill the structures needed to handle the append in mard and call the BAPI_MATERIAL_SAVEDATA
    I hope you are with me so far. From the update_mard I receive some error message handled in the loop that the material couldnt be saved. I assume I have a lock problem. But I cannot get the program to stop when I set a break-point. It simply doesnt stop.
    So two questions:
    1. Can I somehow force my break-points to come in effect?
    2. Can I "postpone" the actual update of MARD until the material document output is processed? If so how? If not, what can I do to avoid my lock problem?
    best regards,
    Glenn

    Hi,
    I have tried to put a break-point just before my error message are created but it still don´t stop. But since I get the error message I know that the flow passes my break-point. It just doesn´t stop. Does it matter if I use break-point or break ?
    I can see lock entries during the processing. I set a wait up to 30 seconds so I have plenty of time to check lock entries, and I see that there are entries.
    My concern is that I want to be able to postpone my processing until the system releases the lock, but preferrably from the function module where I handle my idoc.
    br,
    Glenn

Maybe you are looking for

  • How to clear invoices posted in foreign currency in APP  VERY URGENT

    Hi Sap Gurus, I have posted 2 invoices , one is in inr (local curcy), another one in usd and i have run the app using the t.code f110 local currcy incoive was cleared but usd curcy invoice went to exception list Why this happened? how can i clear for

  • Ipod mini has died

    Help!I just bought accessories for ipod mini 4GB and was working fine till battery died and i tried to recharge it. Now it wont switch on at all. i get no response and my computer doesnt register it either. i have been through all the reset/troublesh

  • My idvd is not completing multiplexing and writting

    my idvd is not working anymore, as when i burn it cannot complete multiplexing and writing

  • Mapping data from two subrecords

    Hi I have a problem with a simple mapping. The source and the target are given. See image for more details: http://www.flickr.com/photos/38594397@N03/3548820512/sizes/o/ The problem is that when the second subrecord is not fillt the data of the secon

  • How do you view files in the icloud

    My iphone has 4.9GB of data backed up to iCloud and I have only the 5G capacity and don't want to buy more.  I moved about half my data off my iPhone and now only have about 2 GB.  After moving the data off the iPhone, I then I backed up my iPhone to