<?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: Regarding selecting data from tables in report? in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607831#M869084</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Retrived from a Clustered Table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
     IMPORT letter = my_table_in
        FROM DATABASE zlmetext(lm) ID text_idx.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You'll have to find where the data was EXPORTed to find the values for some of the parms.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IMPORT letter = my_table_in&lt;/P&gt;&lt;P&gt;  here, I used &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
      EXPORT letterdesc  FROM zlmetext-letterdesc
             letteravail FROM zlmetext-letteravail
             subject     FROM zlmetext-subject
             erdat       FROM zlmetext-erdat
             ernam       FROM zlmetext-ernam
             aedat       FROM zlmetext-aedat
             aenam       FROM zlmetext-aenam
             letter      FROM it_ltr_text
        TO DATABASE zlmetext(lm) ID text_idx.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;In this case, all the fields except letter were stored in the base portion of the table record.   Only Letter was stored in the clustered area.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Becaue I used LETTER, the "key" to the clustered area is now LETTER and my import uses LETTER as the key to find the table that i stored using letter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in this part&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FROM DATABASE zlmetext(lm) ID text_idx.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the &lt;STRONG&gt;lm&lt;/STRONG&gt; is the cluster and must be the same as the export.  This value can NOT be a variable and must be hardcoded as shown.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;text_idx is the built key to retrieve and this is the code I used to create it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA:
  BEGIN OF text_idx,
    appl     LIKE zlmetext-appl,
    letterid LIKE zlmetext-letterid,
    srtf2    LIKE zlmetext-srtf2,
  END OF text_idx.
,
,
,
  text_idx-appl     = zlmetext-appl.
  text_idx-letterid = zlmetext-letterid.
  CLEAR: text_idx-srtf2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 17 Mar 2008 12:04:49 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-03-17T12:04:49Z</dc:date>
    <item>
      <title>Regarding selecting data from tables in report?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607828#M869081</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;How to read the data into the report which is stored in the cluster form in the database its urgent please reply me?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Mar 2008 11:49:28 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607828#M869081</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-17T11:49:28Z</dc:date>
    </item>
    <item>
      <title>Re: Regarding selecting data from tables in report?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607829#M869082</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Use the EXPORT &amp;#133; TO MEMORY statement to copy any number of ABAP variables with their current values (data cluster) to ABAP memory. The ID&amp;#133; addition (maximum 32 characters long) enables you to identify different clusters.&lt;/P&gt;&lt;P&gt;If you use a new EXPORT TO MEMORY statement for an existing data cluster, the new one will overwrite the old.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The IMPORT&amp;#133; FROM MEMORY ID&amp;#133; statement allows you to copy data from ABAP memory into the corresponding fields of your ABAP program. In the IMPORT statement, you can also restrict the selection to a part of the data cluster.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The variables into which you want to read data from the cluster in ABAP memory must have the same types in both the exporting and the importing programs.&lt;/P&gt;&lt;P&gt;To release a data cluster, use the FREE MEMORY ID&amp;#133; statement.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Reward if helpful.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Ramya&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Mar 2008 11:53:17 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607829#M869082</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-17T11:53:17Z</dc:date>
    </item>
    <item>
      <title>Re: Regarding selecting data from tables in report?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607830#M869083</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;WHICH DATA U REQUIRE?&lt;/P&gt;&lt;P&gt;THERE R  3 FUNC.MODULES TO READ THE DATA  FROM  PCL2 CLUSTER.( WHICH STORESPAYROLL RESULTS)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;CU_READ_RGDIR&lt;/P&gt;&lt;P&gt;CU_READ_LAST&lt;/P&gt;&lt;P&gt;PYXX_READ_PAYROLL_RESULT&lt;/P&gt;&lt;P&gt;TRY WITH THIS  IF U WANT PAYROLL DATA&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Mar 2008 11:56:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607830#M869083</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-17T11:56:29Z</dc:date>
    </item>
    <item>
      <title>Re: Regarding selecting data from tables in report?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607831#M869084</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Retrived from a Clustered Table&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
     IMPORT letter = my_table_in
        FROM DATABASE zlmetext(lm) ID text_idx.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You'll have to find where the data was EXPORTed to find the values for some of the parms.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;IMPORT letter = my_table_in&lt;/P&gt;&lt;P&gt;  here, I used &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
      EXPORT letterdesc  FROM zlmetext-letterdesc
             letteravail FROM zlmetext-letteravail
             subject     FROM zlmetext-subject
             erdat       FROM zlmetext-erdat
             ernam       FROM zlmetext-ernam
             aedat       FROM zlmetext-aedat
             aenam       FROM zlmetext-aenam
             letter      FROM it_ltr_text
        TO DATABASE zlmetext(lm) ID text_idx.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;In this case, all the fields except letter were stored in the base portion of the table record.   Only Letter was stored in the clustered area.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Becaue I used LETTER, the "key" to the clustered area is now LETTER and my import uses LETTER as the key to find the table that i stored using letter.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;in this part&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FROM DATABASE zlmetext(lm) ID text_idx.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;the &lt;STRONG&gt;lm&lt;/STRONG&gt; is the cluster and must be the same as the export.  This value can NOT be a variable and must be hardcoded as shown.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;text_idx is the built key to retrieve and this is the code I used to create it&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
DATA:
  BEGIN OF text_idx,
    appl     LIKE zlmetext-appl,
    letterid LIKE zlmetext-letterid,
    srtf2    LIKE zlmetext-srtf2,
  END OF text_idx.
,
,
,
  text_idx-appl     = zlmetext-appl.
  text_idx-letterid = zlmetext-letterid.
  CLEAR: text_idx-srtf2.
&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Mar 2008 12:04:49 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607831#M869084</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-03-17T12:04:49Z</dc:date>
    </item>
    <item>
      <title>Re: Regarding selecting data from tables in report?</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607832#M869085</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;Use import statement to read from database clusters. Also make sure that the data you import is in same memory variables as it was exported.&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;IMPORT itab &lt;/P&gt;&lt;P&gt;  FROM DATABASE indx(ZZ) &lt;/P&gt;&lt;P&gt;  ID 'ZSD344'. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Check SAP online help for IMPORT statement.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 17 Mar 2008 12:08:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/regarding-selecting-data-from-tables-in-report/m-p/3607832#M869085</guid>
      <dc:creator>Rashid_Javed</dc:creator>
      <dc:date>2008-03-17T12:08:33Z</dc:date>
    </item>
  </channel>
</rss>

