Skip to Content
0
Former Member
Jun 17, 2009 at 01:14 PM

Use of lr_core->modify

55 Views

Hi All,

I have to modify these two field values.

lv_inv_std_addr_flag

lv_std_addr_flag

DATA: lv_inv_std_addr_flag TYPE string,
          lv_std_addr_flag   TYPE string,
          lr_core            TYPE REF TO cl_crm_bol_core.

Is it required to use the lr_core->modify( ) statement twice to modify both the values as below

lr_my_context->shipto->set_stdbpaddress( attribute_path = '' value = lv_inv_std_addr_flag ).
  lr_core->modify( ).
  lr_my_context->shipto->set_stdbpaddress( attribute_path = '' value = lv_std_addr_flag ).
  lr_core->modify( ).

Or even the below code also works, beacuse it will be more effective in performance, as we are using lr_core->modify only once.

lr_my_context->shipto->set_stdbpaddress( attribute_path = '' value = lv_inv_std_addr_flag ).
lr_my_context->shipto->set_stdbpaddress( attribute_path = '' value = lv_std_addr_flag ).
lr_core->modify( ).

Edited by: Garg on Jun 17, 2009 4:44 PM