<?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 Re: Problem with GET REFERENCE statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093553#M1814209</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes you would always get reference to the work area.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So use similar solution, with a statement APPEND [INITIAL LINE/wa] TO itab ASSIGNING &amp;lt;fs&amp;gt; and use the field symbol in the get reference statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raymond&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 04 Mar 2014 07:34:01 GMT</pubDate>
    <dc:creator>RaymondGiuseppi</dc:creator>
    <dc:date>2014-03-04T07:34:01Z</dc:date>
    <item>
      <title>Problem with GET REFERENCE statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093550#M1814206</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi gurus,&lt;/P&gt;&lt;P&gt;shortly; I need to populate a table whose elements are made as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CODE&amp;nbsp;&amp;nbsp; TYPE MDM_FIELD_CODE (a string, basically)&lt;/P&gt;&lt;P&gt;VALUE&amp;nbsp; TYPE REF TO DATA.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I need to loop over an item table and populate the above sketched table; so I wrote as follows:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;LOOP &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;AT &lt;/SPAN&gt;lt_item &lt;SPAN class="L0S52"&gt;INTO &lt;/SPAN&gt;ls_item&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt; &lt;SPAN class="L0S31"&gt;*** MDMSRM_SHORT_DESCRIPTION ***&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;CLEAR &lt;/SPAN&gt;value_pair&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;MOVE &lt;/SPAN&gt;&lt;SPAN class="L0S33"&gt;'MDMSRM_SHORT_DESCRIPTION' &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;to &lt;/SPAN&gt;value_pair&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;code&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;GET &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REFERENCE &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;ls_item&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;short_desc &lt;SPAN class="L0S52"&gt;INTO &lt;/SPAN&gt;value_pair-value.&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;APPEND &lt;/SPAN&gt;value_pair &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;lt_value_pair&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;....&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is: each time the loop is performed, all the VALUE fields already appended have the value of the last iteration.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I overcome this problem? Is there a sort of unassignment technique for GET REFERENCE?&lt;/P&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Mar 2014 15:57:12 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093550#M1814206</guid>
      <dc:creator>matteo_montalto</dc:creator>
      <dc:date>2014-03-03T15:57:12Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with GET REFERENCE statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093551#M1814207</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;As you store the reference of the work area field and not of the internal table record field, this is normal behaviour. Look at source sample attached for a solution using ASSIGNING &amp;lt;fs&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raymond&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Mar 2014 16:11:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093551#M1814207</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2014-03-03T16:11:18Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with GET REFERENCE statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093552#M1814208</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks Raymond, &lt;/P&gt;&lt;P&gt;your solution solved my problem.&lt;/P&gt;&lt;P&gt;One more question... in that LOOP cycle, I have to build up a structure in this way:&lt;/P&gt;&lt;P&gt;LOOP... ASSIGNING &amp;lt;item&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; CLEAR &lt;/SPAN&gt;ls_min_qty&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;MOVE &lt;/SPAN&gt;&amp;lt;item&amp;gt;&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;min_qty &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;ls_min_qty&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;content&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;MOVE &lt;/SPAN&gt;&lt;SPAN class="L0S33"&gt;'$$$' &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;ls_min_qty&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;unit_code&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;GET &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REFERENCE &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;ls_min_qty &lt;SPAN class="L0S52"&gt;INTO &lt;/SPAN&gt;value_pair&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;value&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;APPEND &lt;/SPAN&gt;value_pair &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;lt_value_pair&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;---&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;ENDLOOP.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;I assume this would lead to the same problem I posted above, as each GET REFERENCE of structure will overwrite previous assignments. How would you overcome this issue?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;Thanks again&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 03 Mar 2014 16:26:02 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093552#M1814208</guid>
      <dc:creator>matteo_montalto</dc:creator>
      <dc:date>2014-03-03T16:26:02Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with GET REFERENCE statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093553#M1814209</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes you would always get reference to the work area.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So use similar solution, with a statement APPEND [INITIAL LINE/wa] TO itab ASSIGNING &amp;lt;fs&amp;gt; and use the field symbol in the get reference statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Raymond&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Mar 2014 07:34:01 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093553#M1814209</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2014-03-04T07:34:01Z</dc:date>
    </item>
    <item>
      <title>Re: Problem with GET REFERENCE statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093554#M1814210</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Had some difficulties in working with field-symbols as I have to reference to a structure which is partly derived from the workarea and partly fixed...&lt;/P&gt;&lt;P&gt;I did as follows, maybe it's not the best solution, however, seems to work:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;FIELD-SYMBOLS &lt;/SPAN&gt;&amp;lt;item&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;TYPE &lt;/SPAN&gt;zsrm_cat_files_i&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52" style="font-size: 10pt;"&gt;FIELD-SYMBOLS&lt;/SPAN&gt;&lt;SPAN class="L0S55" style="font-size: 10pt;"&gt;: &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;&amp;lt;minqty&amp;gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;/SPAN&gt;&lt;SPAN class="L0S52" style="font-size: 10pt;"&gt;TYPE &lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;mdm_gdt_quantity&lt;/SPAN&gt;&lt;SPAN class="L0S70" style="font-size: 10pt;"&gt;-&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;content&lt;/SPAN&gt;&lt;SPAN class="L0S55" style="font-size: 10pt;"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;FIELD-SYMBOLS&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;: &lt;/SPAN&gt;&amp;lt;minqty_unit&amp;gt; &lt;SPAN class="L0S52"&gt;TYPE &lt;/SPAN&gt;MDM_CDT_MEASURE_UNIT_CODE&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;FIELD-SYMBOLS&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;: &lt;/SPAN&gt;&amp;lt;minqty_struct&amp;gt; &lt;SPAN class="L0S52"&gt;TYPE &lt;/SPAN&gt;mdm_gdt_quantity&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;DATA &lt;/SPAN&gt;minimum_qty &lt;SPAN class="L0S52"&gt;TYPE &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REF &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;mdm_gdt_quantity&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;LOOP ... ASSIGNING &amp;lt;item&amp;gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S55"&gt;...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN class="L0S52"&gt;&amp;nbsp;&amp;nbsp; CREATE &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;DATA &lt;/SPAN&gt;minimum_qty&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;ASSIGN &lt;/SPAN&gt;minimum_qty&lt;SPAN class="L0S70"&gt;-&amp;gt;&lt;/SPAN&gt;* &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;&amp;lt;minqty_struct&amp;gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;ASSIGN &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;COMPONENT &lt;/SPAN&gt;&lt;SPAN class="L0S32"&gt;1 &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;STRUCTURE &lt;/SPAN&gt;&amp;lt;minqty_struct&amp;gt; &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;&amp;lt;minqty&amp;gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;ASSIGN &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;COMPONENT &lt;/SPAN&gt;&lt;SPAN class="L0S32"&gt;2 &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;STRUCTURE &lt;/SPAN&gt;&amp;lt;minqty_struct&amp;gt; &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;&amp;lt;minqty_unit&amp;gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;minqty&amp;gt; &lt;SPAN class="L0S55"&gt;= &lt;/SPAN&gt;&amp;lt;item&amp;gt;&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;min_qty&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &amp;lt;minqty_unit&amp;gt; &lt;SPAN class="L0S55"&gt;= &lt;/SPAN&gt;&lt;SPAN class="L0S33"&gt;'$$$'&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;GET &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;REFERENCE &lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;OF &lt;/SPAN&gt;&amp;lt;minqty_struct&amp;gt; &lt;SPAN class="L0S52"&gt;INTO &lt;/SPAN&gt;value_pair&lt;SPAN class="L0S70"&gt;-&lt;/SPAN&gt;&lt;SPAN class="L0S52"&gt;value&lt;/SPAN&gt;&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;SPAN class="L0S52"&gt;APPEND &lt;/SPAN&gt;value_pair &lt;SPAN class="L0S52"&gt;TO &lt;/SPAN&gt;lt_value_pair&lt;SPAN class="L0S55"&gt;.&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 04 Mar 2014 08:48:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/problem-with-get-reference-statement/m-p/10093554#M1814210</guid>
      <dc:creator>matteo_montalto</dc:creator>
      <dc:date>2014-03-04T08:48:20Z</dc:date>
    </item>
  </channel>
</rss>

