<?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: Looping on ABAP structure's fields in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164150#M458058</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;oh..and replace all reference to dd07l with dd03l like i said in the first statement!...don't know where my brain is this morning!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 25 Apr 2007 07:40:10 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2007-04-25T07:40:10Z</dc:date>
    <item>
      <title>Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164145#M458053</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hey fellows,&lt;/P&gt;&lt;P&gt;I need to loop on all structure's fields and get the name of the field and the value.&lt;/P&gt;&lt;P&gt;how can I do that?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks &amp;amp; regards&lt;/P&gt;&lt;P&gt;Natti Nachmias.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:25:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164145#M458053</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:25:37Z</dc:date>
    </item>
    <item>
      <title>Re: Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164146#M458054</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Is the structure you want to loop on defined in the dictionary...or just in the program?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:27:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164146#M458054</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:27:51Z</dc:date>
    </item>
    <item>
      <title>Re: Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164147#M458055</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the structure is defined in the dictionary you can access the field names for the structure by reading table dd03l with the structure name in the table field...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;you can then using a field symbol to access the data...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;e.g.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data:&lt;/P&gt;&lt;P&gt;  lst_dd07l LIKE dd07l,&lt;/P&gt;&lt;P&gt;  lt_dd07l   LIKE STANDARD TABLE OF lst_dd07l OCCURS 0.&lt;/P&gt;&lt;P&gt;field-symbols:&lt;/P&gt;&lt;P&gt;  &amp;lt;lfs_field&amp;gt;.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * &lt;/P&gt;&lt;P&gt;  from dd07l&lt;/P&gt;&lt;P&gt;  into table lt_dd07l&lt;/P&gt;&lt;P&gt; where tabname = '&amp;lt;YOUR STRUCTURE NAME&amp;gt;'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;loop at lt_dd07l&lt;/P&gt;&lt;P&gt;  into   lst_dd07l.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  ASSIGN (lst_dd07l-fieldname) OF STRUCTURE &amp;lt;your structure name&amp;gt; &lt;/P&gt;&lt;P&gt;          TO &amp;lt;lfs_field&amp;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;at the point you loop through the table you have both the field name and subsequently the &amp;lt;lfs_field&amp;gt; will hold the value assigned to that field in the structure.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:35:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164147#M458055</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:35:18Z</dc:date>
    </item>
    <item>
      <title>Re: Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164148#M458056</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;the statement you are looking for is "Assign component of structure"&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:35:58 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164148#M458056</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:35:58Z</dc:date>
    </item>
    <item>
      <title>Re: Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164149#M458057</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;yup...sorry missed out the component bit!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;assign component (lst_dd07l-fieldname) of structure &amp;lt;your structure&amp;gt; to &amp;lt;lfs_field&amp;gt;.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:38:26 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164149#M458057</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:38:26Z</dc:date>
    </item>
    <item>
      <title>Re: Looping on ABAP structure's fields</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164150#M458058</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;oh..and replace all reference to dd07l with dd03l like i said in the first statement!...don't know where my brain is this morning!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Apr 2007 07:40:10 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/looping-on-abap-structure-s-fields/m-p/2164150#M458058</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-25T07:40:10Z</dc:date>
    </item>
  </channel>
</rss>

