‎2009 Apr 10 9:11 AM
Hi,
I want to update the table bseg.I have the values of belnr,gjahr and bukrs.If i use the keyword "Update" performance issue is occured.How to update the table is someother way.Plz help
‎2009 Apr 10 9:20 AM
Have u tried MODIFY dbtab FROM TABLE itab.
Also try using BAPI's for updating database.
‎2009 Apr 10 9:14 AM
hi,
its not a gud practive to directly update the database table...
instead use some function module to update the database tables.....
then you will not get any performance issues
Regards,
Siddarth
‎2009 Apr 10 9:20 AM
Have u tried MODIFY dbtab FROM TABLE itab.
Also try using BAPI's for updating database.
‎2009 Apr 10 9:34 AM
I tired to use as
MODIFY bseg from gw_bkpf.
gi_bkpf is of type bkpf.This is throwing error.How to correct it
‎2009 Apr 10 9:38 AM
hi ,
please check the data type of gw_bkpf... it should be of type bseg.
use the code given below...
data : w_bseg type bseg.
move-corresponding gw_bkpf to w_bseg.
modify bseg from w_bseg.Regards,
Siddarth
‎2009 Apr 10 9:38 AM
Declare work area of type BSEG . Error is becz u r updating table with workarea of different type
‎2009 Apr 10 9:54 AM
Thanks this is working out.In addition to this have to set a value of the field when i modify the table.In the "Update" statement we have the option is there any way to do the same in MODIFY also
‎2009 Apr 10 9:55 AM
typoes: begin of tyt_bseg,
belnr type bseg-belnr,
end of ty_bseg.
data:it_bseg type standard table of ty_bseg,
wa_bsefg type ty_bseg.
loop at it_bseg into wa_bseg .
modify bseg from wa_bseg.
endloop.
‎2009 Apr 10 9:22 AM
Y ur not using Modify Key word as u said this is not much performance.
‎2009 Apr 10 10:00 AM
Hi,
do not update standard table directly, some inconsistences may occur... Find a BAPI that is useful for you!!!
Regards,
Ivan
‎2009 Apr 10 10:23 AM
Hi,
The MODIFY statement will scan all records in database table before making an UPDATE or an INSERT. That's why you are having performance issues. If you are able to know wether your current record already exists or not use INSERT or UPDATE instead.
DESPITE ALL THIS, YOU SHOULD NEVER UPDATE DIRECTLY A STANDARD DATABASE TABLE.
Use FI function modules or batch input to upadate your data.
Issa
‎2009 Apr 10 10:57 AM
use
modify <dtab> from table <itab>.Regards,
Lalit Mohan Gupta.