<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Move statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575463#M860683</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts,&lt;/P&gt;&lt;P&gt;   I want to know about &lt;/P&gt;&lt;P&gt;1) move&lt;/P&gt;&lt;P&gt;    move corresponding&lt;/P&gt;&lt;P&gt;2) steps to observe to improve the performance&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Nagaraju&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 28 Mar 2008 21:19:01 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-28T21:19:01Z</dc:date>
    <item>
      <title>Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575463#M860683</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Experts,&lt;/P&gt;&lt;P&gt;   I want to know about &lt;/P&gt;&lt;P&gt;1) move&lt;/P&gt;&lt;P&gt;    move corresponding&lt;/P&gt;&lt;P&gt;2) steps to observe to improve the performance&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;Nagaraju&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Mar 2008 21:19:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575463#M860683</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-28T21:19:01Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575464#M860684</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;STRONG&gt;MOVE&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Move the content of an internal table/variable to another internal table/variable&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
MOVE T_TEST-FIELD1 TO T_TEST2-FIELD1.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MOVE-CORRESPONDING&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Move all fields that applied.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
MOVE-CORRESPONDING T_TABLE1 TO T_TABLE2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;IMPROVE PERFORMANCE&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use Field-Symbols.&lt;/P&gt;&lt;P&gt;Avoid Select-Endselect.&lt;/P&gt;&lt;P&gt;Specify full keys or indices.&lt;/P&gt;&lt;P&gt;Avoid unnecessary selects.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Greetings,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Blag.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Mar 2008 21:30:45 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575464#M860684</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-28T21:30:45Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575465#M860685</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;MOVE field by field gives better performance than MOVE-CORRESPONDING as in move-corresponding it checks every field in both ends.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Srinivas&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Mar 2008 21:44:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575465#M860685</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-28T21:44:51Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575466#M860686</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;move-corresponding should have same field names with same structure&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use select up to &amp;lt;n&amp;gt; rows instead of select single if you are not using full key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Avoid using select queries inside the loop endloop instead fetch data into internal table before processing and use read statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Sort internal table before reading. Use binary search if you are using full key.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Avoid cluttered if elseifs instead use case endcase.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Use available index for the tables.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Modularize the code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Avoid multiple joins instead use for all entries.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;While fetching data from huge tables like bseg into internal tables, use package size.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;There are many other tips to improve performance. You can get abundant stuff by searching.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It depends on how you handle the performance based on the situation you come across.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;SKJ&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;SKJ&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 28 Mar 2008 21:49:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575466#M860686</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-28T21:49:05Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575467#M860687</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To assign the value of a data object source to a variable destination, use the following statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE source TO destination.   or the equivalent statement   destination = source.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The content of source remains unchanged, source does not therefore have to be a variable - it can also be a literal, a text symbol, or a constant. You must always specify decimal points with a period (.), regardless of the user&amp;#146;s personal settings.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Multiple assignments f4 = f3 = f2 = f1 are also possible. ABAP processes them from right to left as follows:&lt;/P&gt;&lt;P&gt;MOVE f1 TO f2. MOVE f2 TO f3. MOVE f3 TO f4. &lt;/P&gt;&lt;P&gt;In the MOVE statement (or when you assign one value to another with the equal sign), it is not possible to specify the field names dynamically as the contents of other fields. If you need to do this, you must use field symbols . &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The source and target fields can be of different data types. The result of the value assignment depends on whether these data types are compatible and whether a type conversion can be performed. If there is no conversion rule between the data types in question, no assignment can be made.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: t(10)  TYPE c,&lt;/P&gt;&lt;P&gt;      number TYPE p DECIMALS 2,&lt;/P&gt;&lt;P&gt;      count  TYPE i.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;t = 1111.&lt;/P&gt;&lt;P&gt;MOVE '5.75' TO number.&lt;/P&gt;&lt;P&gt;count = number.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Following these assignments, the fields t, number and count have the values &amp;#145;1111      &amp;#146;, 5.75, and 6 respectively. When you assign the number literal 1111 to T, it is converted into a character field with length 10. When you assign number to count , the decimal number is rounded to an integer (as long as the program attribute Fixed pt. arithmetic has been set).&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Assigning Values Between Components of Structures&lt;/P&gt;&lt;P&gt;The rules for value assignments between data objects also apply to structures. With the command&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: struct1 TYPE structure,&lt;/P&gt;&lt;P&gt;      struct2 TYPE structure.&lt;/P&gt;&lt;P&gt;struct1 = struct2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;two structures of the same type can be assigned to one another without difficulty. Here, the entire source structure is seen as a unit and copied to the source structure. It is then possible to access the components individually again. If the structures in question are not compatible, see the conversion rules for structures.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In practice, however, you will often only need to assign certain components of a structure to be certain components of another structure. ABAP has a special statement for this purpose:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING sourcestruct TO destinationstruct.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This statement assigns the contents of the components of structure sourcestruct to the components of the destinationstruct structure that have identical names.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;When it is executed, it is broken down into a set of MOVEstatements, one for each pair of fields with identical names, as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE sourcestruct-comp1 TO destinationstruct-comp1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE sourcestruct-comp2 TO destinationstruct-comp2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any necessary type conversions are performed individually. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF address,&lt;/P&gt;&lt;P&gt;        firstname(20) TYPE c VALUE 'Fred',&lt;/P&gt;&lt;P&gt;        surname(20) TYPE c VALUE 'Flintstone',&lt;/P&gt;&lt;P&gt;        initials(4) TYPE c VALUE 'FF',&lt;/P&gt;&lt;P&gt;        street(20) TYPE c VALUE 'Cave Avenue',&lt;/P&gt;&lt;P&gt;        number TYPE i VALUE '11',&lt;/P&gt;&lt;P&gt;        postcode(5) TYPE n VALUE '98765',&lt;/P&gt;&lt;P&gt;        city(20) TYPE c VALUE  'Bedrock',&lt;/P&gt;&lt;P&gt;      END OF address.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA: BEGIN OF name,&lt;/P&gt;&lt;P&gt;        surname(20) TYPE c,&lt;/P&gt;&lt;P&gt;        firstname(20) TYPE c,&lt;/P&gt;&lt;P&gt;        initials(4) TYPE c,&lt;/P&gt;&lt;P&gt;        title(10) TYPE c VALUE 'Mister',&lt;/P&gt;&lt;P&gt;      END OF name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MOVE-CORRESPONDING address TO name.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this example, the values of name-surname, name-firstname and name-initials are set to 'Flintstone&amp;#146;, &amp;#145;Fred&amp;#146;, and 'FF'. name-title always has the value &amp;#145;Mister&amp;#146;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;In SUMMARY , move is for moving variables or structures of  same type whereas move-corrresponding is for assigning same fields in different structures.&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;Performance Issues&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;some of the performance improvement tips&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1) Dont use hardcoding i.e variable = 'HELLO', instead create some constants and then assign that constant to the  variable.&lt;/P&gt;&lt;P&gt;2) Dont use LOOP in LOOP&lt;/P&gt;&lt;P&gt;3) Dont use SELECT in LOOP&lt;/P&gt;&lt;P&gt;4) Use Sub routines in case of repititive code&lt;/P&gt;&lt;P&gt;5) Use changing,using with the subroutines&lt;/P&gt;&lt;P&gt;6) before using the read statement sort the table.&lt;/P&gt;&lt;P&gt;7) dont use select-endselect.&lt;/P&gt;&lt;P&gt;&lt;span class="lia-unicode-emoji" title=":smiling_face_with_sunglasses:"&gt;😎&lt;/span&gt; dont use move-corresponding fields.&lt;/P&gt;&lt;P&gt;9) dont use joins instead go for 'for all entries'&lt;/P&gt;&lt;P&gt;10) use hash tables when large volumes of data is there instead of sorted .&lt;/P&gt;&lt;P&gt;11) dont use select *&lt;/P&gt;&lt;P&gt;12) select * into corresponding fields&lt;/P&gt;&lt;P&gt;13) use the indices available for the table.&lt;/P&gt;&lt;P&gt;14) use types instead of occurs.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks and Regards.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 29 Mar 2008 01:03:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575467#M860687</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-29T01:03:33Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575468#M860688</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;One tip:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Make sure while writing SELECT statement , the order of fields in the "WHERE" should follow the order of fiels in the DDIC table.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;use ABAPDOCU transaction code and choose ABAP Program Execution &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward points if my reply is useful&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;~&lt;SUB&gt;Lakshmiraj&lt;/SUB&gt;~&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 29 Mar 2008 05:26:44 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575468#M860688</guid>
      <dc:creator>abapdeveloper20</dc:creator>
      <dc:date>2008-03-29T05:26:44Z</dc:date>
    </item>
    <item>
      <title>Re: Move statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575469#M860689</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Take one example structures&lt;/P&gt;&lt;P&gt;1.structure1:&lt;/P&gt;&lt;P&gt;   field1,&lt;/P&gt;&lt;P&gt;   field2,&lt;/P&gt;&lt;P&gt;   field3,&lt;/P&gt;&lt;P&gt;   field4.&lt;/P&gt;&lt;P&gt;2.Structure2:&lt;/P&gt;&lt;P&gt;   field1,&lt;/P&gt;&lt;P&gt;   field2,&lt;/P&gt;&lt;P&gt;   field3,&lt;/P&gt;&lt;P&gt;   field4.&lt;/P&gt;&lt;P&gt;3.Structure3:&lt;/P&gt;&lt;P&gt;   field2,&lt;/P&gt;&lt;P&gt;   field4,&lt;/P&gt;&lt;P&gt;   field3,&lt;/P&gt;&lt;P&gt;   field1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MOVE&lt;/STRONG&gt; is used to store the values from one structure/variable&lt;/P&gt;&lt;P&gt;to another structure/variable,WHEN both structures are of same type.&lt;/P&gt;&lt;P&gt;Ex:- MOVE structure1 TO structure2.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;STRONG&gt;MOVE-CORRESPONDING&lt;/STRONG&gt; is used to store the values, WHEN both structures are different.&lt;/P&gt;&lt;P&gt;Ex:- MOVE-CORRESPONDING structure1 TO structure3.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward,if it is useful.&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;Chandu&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 29 Mar 2008 06:17:11 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/move-statement/m-p/3575469#M860689</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-29T06:17:11Z</dc:date>
    </item>
  </channel>
</rss>

