<?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 Mapping Line type Data to table data in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400977#M1644797</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;I am trying to refer to a data element present in the line type of a table type which belongs to an import parameter of a smartform. How will i access the data element to use in the where clause of a select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For Eg:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Import Parameter name: PARTNER_H&lt;/P&gt;&lt;P&gt;TYPE: CRMT_OUTPUT_PARTNER_H_COMT  (table type)&lt;/P&gt;&lt;P&gt;The line type attached to this table type is CRMT_OUTPUT_PARTNER_H_COM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This line type is the structure that contains the data element that i need to use. the details are as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Component: RELATION_PARTNER&lt;/P&gt;&lt;P&gt;Component type: BU_PARTNER_GUID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have written a select statement as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE * from BUT000 into I_FS_BUT000 where&lt;/P&gt;&lt;P&gt;  PARTNER_GUID = PARTNER_H-RELATION_H.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have given the input parameter as  PARTNER_H.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It throws me an error that "PARTNER_H" is a table without a header line and therefore has no component called "RELATION_H".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is this the correct way to access the data element?Please help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 07 Dec 2011 11:54:37 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2011-12-07T11:54:37Z</dc:date>
    <item>
      <title>Mapping Line type Data to table data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400977#M1644797</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;I am trying to refer to a data element present in the line type of a table type which belongs to an import parameter of a smartform. How will i access the data element to use in the where clause of a select statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For Eg:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Import Parameter name: PARTNER_H&lt;/P&gt;&lt;P&gt;TYPE: CRMT_OUTPUT_PARTNER_H_COMT  (table type)&lt;/P&gt;&lt;P&gt;The line type attached to this table type is CRMT_OUTPUT_PARTNER_H_COM.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;This line type is the structure that contains the data element that i need to use. the details are as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Component: RELATION_PARTNER&lt;/P&gt;&lt;P&gt;Component type: BU_PARTNER_GUID&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have written a select statement as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE * from BUT000 into I_FS_BUT000 where&lt;/P&gt;&lt;P&gt;  PARTNER_GUID = PARTNER_H-RELATION_H.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I have given the input parameter as  PARTNER_H.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It throws me an error that "PARTNER_H" is a table without a header line and therefore has no component called "RELATION_H".&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is this the correct way to access the data element?Please help.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Dec 2011 11:54:37 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400977#M1644797</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-12-07T11:54:37Z</dc:date>
    </item>
    <item>
      <title>Re: Mapping Line type Data to table data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400978#M1644798</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Neena,&lt;/P&gt;&lt;P&gt;               Since PARTNER_H is an internal table it may have multiple values. If you want only a single entry from BUT000, you ll have to determine which entry from PARTNER_H you need in select query.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If it is always going to have only a single value then , this will work :&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
data: wa_partner_h type line of CRMT_OUTPUT_PARTNER_H_COMT.

Read table partner_h into wa_partner_h index 1.

if sy-subrc is initial.

SELECT SINGLE * from BUT000 into I_FS_BUT000 where
PARTNER_GUID = WA_PARTNER_H-RELATION_H.

endif.

&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Arun&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Dec 2011 12:07:35 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400978#M1644798</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-12-07T12:07:35Z</dc:date>
    </item>
    <item>
      <title>Re: Mapping Line type Data to table data</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400979#M1644799</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Neena,&lt;/P&gt;&lt;P&gt;declaring a variable of type &lt;STRONG&gt;Table type&lt;/STRONG&gt; makes it a table... &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;so need to have a work area for this, or use select with for all entries..&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;with workarea how to proceed, the earlier post is already showing you the code&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;and with FOA:&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;data : lt_but000 type table of but000.
SELECT * from BUT000 into table lt_BUT000 
For all entries in PARTNER_H "==&amp;gt;FOA
where PARTNER_GUID = PARTNER_H-RELATION_H.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Dec 2011 12:18:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/mapping-line-type-data-to-table-data/m-p/8400979#M1644799</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2011-12-07T12:18:49Z</dc:date>
    </item>
  </channel>
</rss>

