Announcement:
wanna exchange links? contact me at sapchatroom@gmail.com.
Posted by
Admin at
IF ls_regup2-ZLSPR = 'X'. ls_regup2-ZLSPR = 'A'. MODIFY *table * lt_regup FROM ls_regup2 TRANSPORTING ZLSPR. ENDIF. ENDLOOP. MODIFY regup FROM TABLE lt_regup. l_updated = sy-dbcnt. MESSAGE i107(ZSCP_MSG) WITH l_updated. tausif check it , you have to use table in fornt of internal table in modify statement apart from that you can also use a where condition in modify statement if required On 6/9/10, Tausif via sap-dev <sap-dev@groups.ittoolbox.com> wrote: > > Posted by Tausif > on Jun 9 at 10:59 AM Hi All, > > I am facing a problem in updating REGUP-ZLSPR (Payment Block) using Table > control. > > As per the requirement of the client we have created a module pool program > were we display the list of documents in table control. > The data is fetched from REGUP table and displayed in table control, the > field REGUP-ZLSPR is displayed as Check-box. > > If the user checks the record We have to update that particular record with > value in database (REGUP-ZLSPR) with value 'A' (blocked). > > When I run the modify statement on save I get sy-subrc as 0, but the > REGUP-ZLSPR is not updated with the values from internal table. > > Below is the code: > > > CASE save_ok. > > WHEN 'AUTH'. > > CLEAR ls_regup2. > REFRESH: lt_regup2. > > lt_regup2 = lt_regup. > > LOOP AT lt_regup INTO ls_regup2. > IF ls_regup2-ZLSPR = 'X'. > ls_regup2-ZLSPR = 'A'. > MODIFY lt_regup FROM ls_regup2 TRANSPORTING ZLSPR. > ENDIF. > ENDLOOP. > > MODIFY regup FROM TABLE lt_regup. > l_updated = sy-dbcnt. > > MESSAGE i107(ZSCP_MSG) WITH l_updated. > > > Do we have any restriction for updating ZLSPR or is there any problem in > the code. > Please suggest approach to solve the above issue. > > Thanks in advance. > > Regards, > Tausif | __.____._ Copyright © 2010 Toolbox.com and message author. Toolbox.com 4343 N. Scottsdale Road Suite 280, Scottsdale, AZ 85251 | | _.____.__ |