<?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: data from a field into a structure in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505880#M1422639</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The data in the field PRELP-DATA1 needs to be seperated...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 31 Dec 2009 13:37:27 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2009-12-31T13:37:27Z</dc:date>
    <item>
      <title>data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505878#M1422637</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi all,&lt;/P&gt;&lt;P&gt;There is  field in a structure which contains data in the form of a flat file. I need to break this data and fill it in the respective fields of another structure.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please suggest some fucntion module for the same or may b some ways to do this..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;P&gt;Deepti&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 13:03:18 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505878#M1422637</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T13:03:18Z</dc:date>
    </item>
    <item>
      <title>Re: data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505879#M1422638</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Deepti............what u can do is...&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SPLIT the data into the fields of structure&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
SPLIT lv_string2 AT cl_abap_char_utilities=&amp;gt;horizontal_tab      "if its TAB separated records i.e. 'xls'.
INTO ls_struct-field1 ls_struct-field2.

SPLIT lv_string2 AT ','      "if its comma separated records i.e. 'csv'.
INTO ls_struct-field1 ls_struct-field2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 13:22:13 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505879#M1422638</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T13:22:13Z</dc:date>
    </item>
    <item>
      <title>Re: data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505880#M1422639</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The data in the field PRELP-DATA1 needs to be seperated...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 13:37:27 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505880#M1422639</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T13:37:27Z</dc:date>
    </item>
    <item>
      <title>Re: data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505881#M1422640</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Please look at the sample below code &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;&amp;lt; Please respect the 2,500 character posting limit. Post only the relevant portion of your code &amp;gt;&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in the above code iam spliting the line and assiging into wa_mat and alter appending into &lt;/P&gt;&lt;P&gt;internal table it_mat.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Please create a similar program like this&lt;/P&gt;&lt;P&gt; let me know if youneed further information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Satish Boguda&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Edited by: Rob Burbank on Dec 31, 2009 11:29 PM&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 14:51:05 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505881#M1422640</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T14:51:05Z</dc:date>
    </item>
    <item>
      <title>Re: data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505882#M1422641</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Deepti , &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If you are knowing the how the data is stored in the file i.e no , name , length , order and type of fields then just declare type in same format .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;After this you can move the values of fields into the workarea or internal table. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope this helps you.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 15:09:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505882#M1422641</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2009-12-31T15:09:21Z</dc:date>
    </item>
    <item>
      <title>Re: data from a field into a structure</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505883#M1422642</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is no function module, so you will have to do this 'manually'. But you do need some additional info on the fields contained in your field of the structure. The most important thing is the length of all individual fields from this structure field. Using the length you have to move them one by one to your new data field. Second thing that could be of importance is the field definition (Type), for example is it a character field, numeric field or maybe a date. If you have determined this, what is the format of this date, is it YYYYMMDD or DDMMYYYY etc.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Example.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The field of your structure is of type string (undefined length) and has 3 fields without separator.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Vohra     Deepthi   20091231&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;As you can see, this is Lastname (length 10), Firstname (length 10) and current date.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Variables to declare:&lt;/P&gt;&lt;P&gt;data: lvc_firstname(10) type c,&lt;/P&gt;&lt;P&gt;         lvc_lastname(10) type c,&lt;/P&gt;&lt;P&gt;         lvd_current_date type d.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Move the fields from structure to variables:&lt;/P&gt;&lt;P&gt;lvc_lastname = structure-field+0(10).&lt;/P&gt;&lt;P&gt;lvc_firstname = structure-field+10(10).&lt;/P&gt;&lt;P&gt;lvd_current_date = structure-field+20(8).&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 31 Dec 2009 15:11:56 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/data-from-a-field-into-a-structure/m-p/6505883#M1422642</guid>
      <dc:creator>Sm1tje</dc:creator>
      <dc:date>2009-12-31T15:11:56Z</dc:date>
    </item>
  </channel>
</rss>

