<?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: getting text in simple list in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971138#M701173</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is an error in the SELECT query&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from ekko into corresponding fields of itab where bedat in date and FRGKE ne 'R' .&lt;/P&gt;&lt;P&gt;itab-sr_no1 = ctr .&lt;/P&gt;&lt;P&gt;append itab .&lt;/P&gt;&lt;P&gt;ctr = ctr + 1 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endselect .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(bedat in date) what is the value of date, its not passed anywhere.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another thing I noted is you have written&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   LOOP AT itab_lines.&lt;/P&gt;&lt;P&gt;       APPEND itab.&lt;/P&gt;&lt;P&gt;   ENDLOOP.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Its possible that itab gets added with values everytime and there is no way the loop can stop.&lt;/P&gt;&lt;P&gt;Check on the looping. Otherwise the report works fine. To check on that comment the SELECT query mentioned above you can see the result for yourself.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 25 Oct 2007 05:57:22 GMT</pubDate>
    <dc:creator>Sathish</dc:creator>
    <dc:date>2007-10-25T05:57:22Z</dc:date>
    <item>
      <title>getting text in simple list</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971135#M701170</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;  I want to display the text for corresponding po number in simple report.&lt;/P&gt;&lt;P&gt;below is sample codding . but when i execute it , it goes in infinity loop and not executed . so pls suggest me that hw can i get the text for this report.&lt;/P&gt;&lt;P&gt;thanks in advance  .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data :ctr(3) type n value 1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;DATA:F_TDOBJECT LIKE THEAD-TDOBJECT,&lt;/P&gt;&lt;P&gt;      F_TDNAME LIKE THEAD-TDNAME,&lt;/P&gt;&lt;P&gt;      F_TDID LIKE THEAD-TDID,&lt;/P&gt;&lt;P&gt;      ITAB_LINES LIKE TLINE OCCURS 0 WITH HEADER LINE.&lt;/P&gt;&lt;P&gt;DATA:BEGIN OF ITAB1 OCCURS 10,&lt;/P&gt;&lt;P&gt;  ebeln like ekpo-ebeln ,&lt;/P&gt;&lt;P&gt;  DESC(72),&lt;/P&gt;&lt;P&gt;  END OF ITAB1.&lt;/P&gt;&lt;P&gt;data : begin of itab occurs 0 ,&lt;/P&gt;&lt;P&gt;        ebeln like ekko-ebeln,&lt;/P&gt;&lt;P&gt;  bedat like ekko-bedat ,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  lifnr like ekko-lifnr ,&lt;/P&gt;&lt;P&gt;  sr_no1(3) type n ,&lt;/P&gt;&lt;P&gt;  name1 like lfa1-name1 ,&lt;/P&gt;&lt;P&gt;  batxt like T161T-batxt ,&lt;/P&gt;&lt;P&gt;  bsart like ekko-bsart ,&lt;/P&gt;&lt;P&gt;  tdline like tline-tdline ,&lt;/P&gt;&lt;P&gt; end of itab .&lt;/P&gt;&lt;P&gt;format intensified color = 5 .&lt;/P&gt;&lt;P&gt;    format intensified off .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from ekko into corresponding fields of itab where bedat in date and FRGKE ne 'R' .&lt;/P&gt;&lt;P&gt;itab-sr_no1 = ctr .&lt;/P&gt;&lt;P&gt;append itab .&lt;/P&gt;&lt;P&gt;ctr = ctr + 1 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endselect .&lt;/P&gt;&lt;P&gt;loop at itab .&lt;/P&gt;&lt;P&gt;select single * from T161T into corresponding fields of itab where BSART = itab-BSART and SPRAS = 'E' and BSTYP = 'F' .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;modify itab TRANSPORTING batxt.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select single *  from lfa1 into corresponding fields of itab where lifnr = itab-lifnr .&lt;/P&gt;&lt;P&gt;modify itab TRANSPORTING name1.&lt;/P&gt;&lt;P&gt;endloop .&lt;/P&gt;&lt;P&gt;clear itab .&lt;/P&gt;&lt;P&gt;*select * from ekpo into corresponding fields of i_ekpo where ebeln = i_ekko-ebeln .&lt;/P&gt;&lt;P&gt;*append i_ekpo .&lt;/P&gt;&lt;P&gt;loop at itab .&lt;/P&gt;&lt;P&gt;F_TDID = 'F01'.&lt;/P&gt;&lt;P&gt;F_TDNAME = itab-ebeln .&lt;/P&gt;&lt;P&gt;F_TDOBJECT = 'EKKO' .&lt;/P&gt;&lt;P&gt;*endloop .&lt;/P&gt;&lt;P&gt;  call function 'READ_TEXT'&lt;/P&gt;&lt;P&gt;exporting&lt;/P&gt;&lt;P&gt; client                       = sy-mandt&lt;/P&gt;&lt;P&gt;id                            = F_TDID&lt;/P&gt;&lt;P&gt;language                      = 'E'&lt;/P&gt;&lt;P&gt;name                          = F_TDNAME&lt;/P&gt;&lt;P&gt;object                        = F_TDOBJECT&lt;/P&gt;&lt;P&gt;tables&lt;/P&gt;&lt;P&gt;lines                         = ITAB_LINES&lt;/P&gt;&lt;P&gt;EXCEPTIONS&lt;/P&gt;&lt;P&gt;  ID = 1&lt;/P&gt;&lt;P&gt;  LANGUAGE = 2&lt;/P&gt;&lt;P&gt;  NAME = 3&lt;/P&gt;&lt;P&gt;  NOT_FOUND = 4&lt;/P&gt;&lt;P&gt;  OBJECT = 5&lt;/P&gt;&lt;P&gt;  REFERENCE_CHECK = 6&lt;/P&gt;&lt;P&gt;  WRONG_ACCESS_TO_ARCHIVE = 7&lt;/P&gt;&lt;P&gt;  OTHERS = 8.&lt;/P&gt;&lt;P&gt;  IF sy-subrc &amp;lt;&amp;gt; 0.&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;MESSAGE ID SY-MSGID TYPE SY-MSGTY NUMBER SY-MSGNO&lt;/P&gt;&lt;/LI&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;        WITH SY-MSGV1 SY-MSGV2 SY-MSGV3 SY-MSGV4.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;  DESCRIBE TABLE ITAB_LINES LINES SY-TFILL.&lt;/P&gt;&lt;P&gt;  IF SY-TFILL &amp;gt; 0.&lt;/P&gt;&lt;P&gt;    LOOP AT ITAB_LINES.&lt;/P&gt;&lt;P&gt;      ITAB1-ebeln = itab-ebeln.&lt;/P&gt;&lt;P&gt;      ITAB1-DESC = ITAB_LINES-TDLINE.&lt;/P&gt;&lt;P&gt;      APPEND ITAB.&lt;/P&gt;&lt;P&gt;      CLEAR ITAB.&lt;/P&gt;&lt;P&gt;      ENDLOOP.&lt;/P&gt;&lt;P&gt;      ENDIF.&lt;/P&gt;&lt;P&gt; endloop .&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;read table it6 index 1.&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;**loop at it6.&lt;/P&gt;&lt;P&gt;*itab-TDLINE = IT6-TDLINE.&lt;/P&gt;&lt;P&gt;**MODIFY i_ekko TRANSPORTING TDLINE.&lt;/P&gt;&lt;P&gt;loop at itab .&lt;/P&gt;&lt;P&gt;write : /3 itab-sr_no1, 10 sy-vline , 11 itab-ebeln , 21 sy-vline , 22 itab-bedat , 33 sy-vline , 34 itab-lifnr , 48 sy-vline , 49 itab-name1 , 100 sy-vline , 101 itab-BATXT  , 118 sy-vline  , 119 ITAB1-DESC.&lt;/P&gt;&lt;P&gt;HIDE : Itab-EBELN .&lt;/P&gt;&lt;P&gt;endloop .&lt;/P&gt;&lt;P&gt;*CLEAR IT6.&lt;/P&gt;&lt;P&gt;*FREE IT6.&lt;/P&gt;&lt;P&gt;ULINE .&lt;/P&gt;&lt;P&gt;top-of-page .&lt;/P&gt;&lt;P&gt;  format intensified color = 8.&lt;/P&gt;&lt;P&gt;    format intensified off .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write : /3 'DATE :', SY-DATUM , 35 ' PURCHASE ORDER TO BE RELEASED', 90 'PAGE NO :' ,SY-PAGNO  ,&lt;/P&gt;&lt;P&gt;        /36 'FROM' , DATE-LOW , 'TO' , DATE-HIGH   .&lt;/P&gt;&lt;P&gt;ULINE .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  format intensified color = 3.&lt;/P&gt;&lt;P&gt;    format intensified off .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;write : /3 'SR. NO' , 10 sy-vline , 11 'PO NUMBER' , 21 sy-vline , 22 'PO DATE' , 33 sy-vline , 34 'SUPPLIER CODE' , 48 sy-vline , 49 'SUPPLIERS NAME' , 100 sy-vline , 101 'DOC. TYPE'  , 118 sy-vline .&lt;/P&gt;&lt;P&gt;ULINE .&lt;/P&gt;&lt;P&gt;AT LINE-SELECTION .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; set parameter ID 'BES' FIELD Itab-EBELN .&lt;/P&gt;&lt;P&gt;CALL TRANSACTION 'ME23N' AND SKIP FIRST SCREEN .&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Oct 2007 05:34:19 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971135#M701170</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-25T05:34:19Z</dc:date>
    </item>
    <item>
      <title>Re: getting text in simple list</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971136#M701171</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Prasad,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You have not following standard coding guidelines.&lt;/P&gt;&lt;P&gt;Please change following:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1. Select query should not be with SELECT ENDSELECT.. remove ENdselect.. retrieve all the data into internal table without endselect&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;select * from ekko into table itab where bedat in date and FRGKE ne 'R' .&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;ctr = 1.
loop at itab.
itab-sr_no1 = ctr .
ctr = ctr + 1 .
modify itab.
endloop.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2. Select query should not be inside a Loop. Instead use FOR ALL ENTRIES&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;if not itab[] is initial.
select * from mara
 into table imara
 for all entries in itab
 where matnr = itab-matnr.
endif.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Oct 2007 05:38:29 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971136#M701171</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-25T05:38:29Z</dc:date>
    </item>
    <item>
      <title>Re: getting text in simple list</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971137#M701172</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi&lt;/P&gt;&lt;P&gt;Since you are fetching the Header text for the PO&lt;/P&gt;&lt;P&gt;keep it in the EKKO table Internal table Loop and append to the same internal table&lt;/P&gt;&lt;P&gt;into a last text field Or read the it_ekko and pass the EBELn field to this fun module OBJECTNAME field&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;P&gt;Anji&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Oct 2007 05:39:14 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971137#M701172</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-10-25T05:39:14Z</dc:date>
    </item>
    <item>
      <title>Re: getting text in simple list</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971138#M701173</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;There is an error in the SELECT query&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select * from ekko into corresponding fields of itab where bedat in date and FRGKE ne 'R' .&lt;/P&gt;&lt;P&gt;itab-sr_no1 = ctr .&lt;/P&gt;&lt;P&gt;append itab .&lt;/P&gt;&lt;P&gt;ctr = ctr + 1 .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;endselect .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;(bedat in date) what is the value of date, its not passed anywhere.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Another thing I noted is you have written&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;LOOP AT itab.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;   LOOP AT itab_lines.&lt;/P&gt;&lt;P&gt;       APPEND itab.&lt;/P&gt;&lt;P&gt;   ENDLOOP.&lt;/P&gt;&lt;P&gt;ENDLOOP.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Its possible that itab gets added with values everytime and there is no way the loop can stop.&lt;/P&gt;&lt;P&gt;Check on the looping. Otherwise the report works fine. To check on that comment the SELECT query mentioned above you can see the result for yourself.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 25 Oct 2007 05:57:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/getting-text-in-simple-list/m-p/2971138#M701173</guid>
      <dc:creator>Sathish</dc:creator>
      <dc:date>2007-10-25T05:57:22Z</dc:date>
    </item>
  </channel>
</rss>

