<?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: CONVERT a field table in a SELECT statement in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022994#M961368</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;No, but you could move var1 to a type n variable to get the leading zeros and then compare with that variable&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It doesn't work because I don't know how many zeros are in the field1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Raffaele&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 09 Jun 2008 15:28:25 GMT</pubDate>
    <dc:creator>Former Member</dc:creator>
    <dc:date>2008-06-09T15:28:25Z</dc:date>
    <item>
      <title>CONVERT a field table in a SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022991#M961365</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;&lt;/P&gt;&lt;P&gt;I have the follow SELECT statement:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;SELECT SINGLE * FROM table1 INTO wa1&lt;/P&gt;&lt;P&gt;WHERE &lt;/P&gt;&lt;P&gt; field1 = var1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The problem is that field1 DataType is CHAR10 and var1 DataType is I. So if field1 contains '0123' and var1 = '123' the SELECT fails.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there any way to consider field1 as an Integer?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Raffaele&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Jun 2008 14:56:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022991#M961365</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-09T14:56:51Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT a field table in a SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022992#M961366</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;No, but you could move var1 to a type n variable to get the leading zeros and then compare with that variable&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Jun 2008 14:58:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022992#M961366</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-09T14:58:59Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT a field table in a SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022993#M961367</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;do this way  ..Convert it to char data type&lt;/P&gt;&lt;P&gt; &lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;
data : var1 like table1-field1 value '0123'.

SELECT SINGLE * FROM table1 INTO wa1
WHERE
field1 = var1. &lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Jun 2008 15:03:33 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022993#M961367</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-09T15:03:33Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT a field table in a SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022994#M961368</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;PRE&gt;&lt;CODE&gt;&lt;P&gt;No, but you could move var1 to a type n variable to get the leading zeros and then compare with that variable&lt;/P&gt;&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It doesn't work because I don't know how many zeros are in the field1.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Best Regards,&lt;/P&gt;&lt;P&gt;Raffaele&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Jun 2008 15:28:25 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022994#M961368</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-09T15:28:25Z</dc:date>
    </item>
    <item>
      <title>Re: CONVERT a field table in a SELECT statement</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022995#M961369</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;use the FM : CONVERSION_EXIT_ALPHA_OUTPUT to quit the zeros of any variable.&lt;/P&gt;&lt;P&gt; example&lt;/P&gt;&lt;P&gt;if u have 000945&lt;/P&gt;&lt;P&gt;after call FM u obtain only 945&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 09 Jun 2008 15:44:22 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/convert-a-field-table-in-a-select-statement/m-p/4022995#M961369</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2008-06-09T15:44:22Z</dc:date>
    </item>
  </channel>
</rss>

