<?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 select in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226820#M138129</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;im getting some problems with the program when im trying to achieving this&lt;/P&gt;&lt;P&gt;    select all LIFSP from table TVLSP for LFART eq ' LF'&lt;/P&gt;&lt;P&gt;    get description from table TVLST&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i wrote the code like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM f_extract_delivery_blocks .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR i_tvlsp.&lt;/P&gt;&lt;P&gt;  REFRESH i_tvlsp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SELECT lifsp lfart INTO TABLE i_tvlsp&lt;/P&gt;&lt;P&gt;  FROM tvlsp&lt;/P&gt;&lt;P&gt;  WHERE lfart EQ c_lf.                  " c_lf value LF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;    PERFORM f_send_message USING 'TVLSP'.&lt;/P&gt;&lt;P&gt;    RETURN.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select spras lifsp vtext into corresponding fields of table i_tvlst&lt;/P&gt;&lt;P&gt;from tvlst&lt;/P&gt;&lt;P&gt;for all entries in i_tvlsp&lt;/P&gt;&lt;P&gt;where lifsp eq i_tvlsp-lifsp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If sy-subrc = 0.&lt;/P&gt;&lt;P&gt;  sort i_tvlst by lifsp vtext.&lt;/P&gt;&lt;P&gt;else.&lt;/P&gt;&lt;P&gt;    PERFORM f_send_message USING 'TVLST'.&lt;/P&gt;&lt;P&gt;    RETURN.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Transfer to the consolidated table&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  LOOP AT i_tvlsp.&lt;/P&gt;&lt;P&gt;    CLEAR : i_cons_tab.&lt;/P&gt;&lt;P&gt;   MOVE c_lf      TO i_cons_tab-id.&lt;/P&gt;&lt;P&gt;    MOVE i_tvlsp-lifsp TO i_cons_tab-dlb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    read table i_tvlst with table key lifsp = c_lf.&lt;/P&gt;&lt;P&gt;    if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;    move i_tvlst-spras to i_cons_tab-spras.&lt;/P&gt;&lt;P&gt;    MOVE i_tvlst-vtext TO i_cons_tab-text.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    APPEND i_cons_tab.&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; im getting error like &lt;/P&gt;&lt;P&gt;The declaration for the key field "VTEXT" is incomplete. However,"VTEXT" is is contained in the key of table "I_TVLST". and must be filled.		&lt;/P&gt;&lt;P&gt;		&lt;/P&gt;&lt;P&gt;2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Config Table - TVAPT - Extract only Z prefixed values and text. how can extract value pstyv from table tvapt where pstyv starts with z.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;could somebody help me with this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;/P&gt;&lt;P&gt;kiran.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 14 Mar 2006 12:02:03 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2006-03-14T12:02:03Z</dc:date>
    <item>
      <title>select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226820#M138129</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;im getting some problems with the program when im trying to achieving this&lt;/P&gt;&lt;P&gt;    select all LIFSP from table TVLSP for LFART eq ' LF'&lt;/P&gt;&lt;P&gt;    get description from table TVLST&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;i wrote the code like this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;FORM f_extract_delivery_blocks .&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  CLEAR i_tvlsp.&lt;/P&gt;&lt;P&gt;  REFRESH i_tvlsp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  SELECT lifsp lfart INTO TABLE i_tvlsp&lt;/P&gt;&lt;P&gt;  FROM tvlsp&lt;/P&gt;&lt;P&gt;  WHERE lfart EQ c_lf.                  " c_lf value LF&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  IF sy-subrc NE 0.&lt;/P&gt;&lt;P&gt;    PERFORM f_send_message USING 'TVLSP'.&lt;/P&gt;&lt;P&gt;    RETURN.&lt;/P&gt;&lt;P&gt;  ENDIF.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;select spras lifsp vtext into corresponding fields of table i_tvlst&lt;/P&gt;&lt;P&gt;from tvlst&lt;/P&gt;&lt;P&gt;for all entries in i_tvlsp&lt;/P&gt;&lt;P&gt;where lifsp eq i_tvlsp-lifsp.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If sy-subrc = 0.&lt;/P&gt;&lt;P&gt;  sort i_tvlst by lifsp vtext.&lt;/P&gt;&lt;P&gt;else.&lt;/P&gt;&lt;P&gt;    PERFORM f_send_message USING 'TVLST'.&lt;/P&gt;&lt;P&gt;    RETURN.&lt;/P&gt;&lt;P&gt;endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Transfer to the consolidated table&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;  LOOP AT i_tvlsp.&lt;/P&gt;&lt;P&gt;    CLEAR : i_cons_tab.&lt;/P&gt;&lt;P&gt;   MOVE c_lf      TO i_cons_tab-id.&lt;/P&gt;&lt;P&gt;    MOVE i_tvlsp-lifsp TO i_cons_tab-dlb.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    read table i_tvlst with table key lifsp = c_lf.&lt;/P&gt;&lt;P&gt;    if sy-subrc = 0.&lt;/P&gt;&lt;P&gt;    move i_tvlst-spras to i_cons_tab-spras.&lt;/P&gt;&lt;P&gt;    MOVE i_tvlst-vtext TO i_cons_tab-text.&lt;/P&gt;&lt;P&gt;    endif.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;    APPEND i_cons_tab.&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; im getting error like &lt;/P&gt;&lt;P&gt;The declaration for the key field "VTEXT" is incomplete. However,"VTEXT" is is contained in the key of table "I_TVLST". and must be filled.		&lt;/P&gt;&lt;P&gt;		&lt;/P&gt;&lt;P&gt;2)&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SAP Config Table - TVAPT - Extract only Z prefixed values and text. how can extract value pstyv from table tvapt where pstyv starts with z.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;could somebody help me with this.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;thanks,&lt;/P&gt;&lt;P&gt;kiran.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2006 12:02:03 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226820#M138129</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-03-14T12:02:03Z</dc:date>
    </item>
    <item>
      <title>Re: select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226821#M138130</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kiran.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;instead of read, use Loop with where condition..dat works.&lt;/P&gt;&lt;P&gt;also for 2nd query u can use select  **** where pstyv like 'Z%'.&lt;/P&gt;&lt;P&gt;Hope it helps.&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Bikash&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2006 12:09:52 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226821#M138130</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-03-14T12:09:52Z</dc:date>
    </item>
    <item>
      <title>Re: select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226822#M138131</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I'll try to answer the secong question first.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;do like this&lt;/P&gt;&lt;P&gt; select *&lt;/P&gt;&lt;P&gt;   from tvapt&lt;/P&gt;&lt;P&gt;   into table t_tvapt&lt;/P&gt;&lt;P&gt;   where pstyv like 'Z%'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;UL&gt;&lt;LI level="1" type="ul"&gt;&lt;P&gt;Sample usage of like statement:&lt;/P&gt;&lt;/LI&gt;&lt;/UL&gt;&lt;P&gt;PARAMETERS srch_str(20) TYPE c. &lt;/P&gt;&lt;P&gt;CONCATENATE '%' srch_str '%' INTO srch_str. &lt;/P&gt;&lt;P&gt;DATA text_tab TYPE TABLE OF doktl. &lt;/P&gt;&lt;P&gt;SELECT * &lt;/P&gt;&lt;P&gt;       FROM doktl &lt;/P&gt;&lt;P&gt;       INTO TABLE text_tab &lt;/P&gt;&lt;P&gt;       WHERE doktext LIKE srch_str. &lt;/P&gt;&lt;P&gt;REgards,&lt;/P&gt;&lt;P&gt;Ravi&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2006 12:12:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226822#M138131</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-03-14T12:12:59Z</dc:date>
    </item>
    <item>
      <title>Re: select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226823#M138132</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Kiran,&lt;/P&gt;&lt;P&gt;1. Couldn't figure out your first error.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;2.SAP Config Table - TVAPT - Extract only Z prefixed values and text. how can extract value pstyv from table tvapt where pstyv starts with z.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;You can extract field values starting with Z* with the following code.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;RANGES range for tvapt-pstyv.
range-sign = 'I'.
range-option = 'CP'.
range-low = 'Z*'.
APPEND range.

TABLES tvapt.
SELECT * FROM tvapt INTO TABLE itab WHERE pstyv IN range.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Wenceslaus.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2006 12:20:41 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226823#M138132</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-03-14T12:20:41Z</dc:date>
    </item>
    <item>
      <title>Re: select</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226824#M138133</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Regarding the first question of yours, the error is something related to the declaration, so paste your declaration of the variables.&lt;/P&gt;&lt;P&gt;And one more thing is that when you use the for all entries statement,&lt;/P&gt;&lt;P&gt;you better check for initial before the select.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if not i_tvlst[] is initial.&lt;/P&gt;&lt;P&gt;select spras lifsp vtext into corresponding fields of table i_tvlst&lt;/P&gt;&lt;P&gt;from tvlst&lt;/P&gt;&lt;P&gt;for all entries in i_tvlsp&lt;/P&gt;&lt;P&gt;where lifsp eq i_tvlsp-lifsp.&lt;/P&gt;&lt;P&gt;Endif.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Mar 2006 12:30:21 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/select/m-p/1226824#M138133</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2006-03-14T12:30:21Z</dc:date>
    </item>
  </channel>
</rss>

