Application Development Blog Posts
Learn and share on deeper, cross technology development topics such as integration and connectivity, automation, cloud extensibility, developing at scale, and security.
cancel
Showing results for 
Search instead for 
Did you mean: 
0 Kudos
During some tests with a huge amount of data a a colleague of me Dirk Freundel gets unexpected performance finding between:

  1. MOVE-CORRESPONDING struc1 TO struc2

  2. MOVE-CORRESPONDING itab1 TO itab2


He put 1.000.000 lines of a table with 27 columns into a internal table with 16 columns. Variant 1 needed about 179 ms less time than variant 2.



Test code:
DO 10 TIMES.

* Init
FREE lt_middle.

* Runtime
GET RUN TIME FIELD lv_runtime_a.

* LOOP
LOOP AT lt_database ASSIGNING <fs_database>.

MOVE-CORRESPONDING <fs_database> TO ls_middle.
INSERT ls_middle INTO TABLE lt_middle.

ENDLOOP.

* OR TABLE
"MOVE-CORRESPONDING lt_database TO lt_middle.

* Runtime
GET RUN TIME FIELD lv_runtime_b.
lv_runtime_b = ( lv_runtime_b - lv_runtime_a ) / 1000.
WRITE: / SY-INDEX, ' Runtime [msec]: ', lv_runtime_b.

ENDDO.

Has anybody else observed the same performance finding, Please add a comment.

 
2 Comments