<?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: type incompatible problem... in Application Development and Automation Discussions</title>
    <link>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147622#M453188</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I fear you have to remove the varying and replace them with &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;pos = sy-index - 1.
c = p+pos(1).
n = p+sy-index(1).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;(less elegant)&lt;/P&gt;&lt;P&gt;I always used varying with subfields of a structure not with characters of a field. Abap documentation points on fields :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;i&amp;gt;This addition is useful if you have a series of fields of the same type and the same distance from each other.&amp;lt;/i&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sat, 07 Apr 2007 09:04:59 GMT</pubDate>
    <dc:creator>RaymondGiuseppi</dc:creator>
    <dc:date>2007-04-07T09:04:59Z</dc:date>
    <item>
      <title>type incompatible problem...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147619#M453185</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;When i m executing this code an error " p &amp;amp; c are type incompatible" is coming.&lt;/P&gt;&lt;P&gt;Please advise.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  REPORT ztx1013.&lt;/P&gt;&lt;P&gt;  PARAMETERS p(20) DEFAULT 'c::&lt;BR /&gt;\xxx&lt;BR /&gt;yyy'.&lt;/P&gt;&lt;P&gt;  DATA: c,                    "current character&lt;/P&gt;&lt;P&gt;        n.                    "next    character&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;  DO 19 TIMES VARYING c FROM p&lt;EM&gt;0 NEXT p&lt;/EM&gt;1&lt;/P&gt;&lt;P&gt;              VARYING n FROM p&lt;EM&gt;1 NEXT p&lt;/EM&gt;2.&lt;/P&gt;&lt;P&gt;    IF c NA ':\'.&lt;/P&gt;&lt;P&gt;      CONTINUE.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;    IF c = n.&lt;/P&gt;&lt;P&gt;      WRITE: / 'duplicate', c, 'found', 'at position', sy-index.&lt;/P&gt;&lt;P&gt;    ENDIF.&lt;/P&gt;&lt;P&gt;  ENDDO.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 Apr 2007 08:28:51 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147619#M453185</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-07T08:28:51Z</dc:date>
    </item>
    <item>
      <title>Re: type incompatible problem...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147620#M453186</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Try &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;REPORT ztx1013.
PARAMETERS p(20) DEFAULT 'c::\xxx\yyy'.
DATA: c, "current character
n. "next character

DO 19 TIMES VARYING c FROM p+0(1) NEXT p+1(1)
VARYING n FROM p+1(1) NEXT p+2(1).
IF c NA ':'.
CONTINUE.
ENDIF.
IF c = n.
WRITE: / 'duplicate', c, 'found', 'at position', sy-index.
ENDIF.
ENDDO.&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 Apr 2007 08:40:20 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147620#M453186</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2007-04-07T08:40:20Z</dc:date>
    </item>
    <item>
      <title>Re: type incompatible problem...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147621#M453187</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;this is not working.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 Apr 2007 08:50:15 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147621#M453187</guid>
      <dc:creator>Former Member</dc:creator>
      <dc:date>2007-04-07T08:50:15Z</dc:date>
    </item>
    <item>
      <title>Re: type incompatible problem...</title>
      <link>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147622#M453188</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I fear you have to remove the varying and replace them with &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;PRE&gt;&lt;CODE&gt;pos = sy-index - 1.
c = p+pos(1).
n = p+sy-index(1).&lt;/CODE&gt;&lt;/PRE&gt;&lt;P&gt;(less elegant)&lt;/P&gt;&lt;P&gt;I always used varying with subfields of a structure not with characters of a field. Abap documentation points on fields :&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&amp;lt;i&amp;gt;This addition is useful if you have a series of fields of the same type and the same distance from each other.&amp;lt;/i&amp;gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 07 Apr 2007 09:04:59 GMT</pubDate>
      <guid>https://community.sap.com/t5/application-development-and-automation-discussions/type-incompatible-problem/m-p/2147622#M453188</guid>
      <dc:creator>RaymondGiuseppi</dc:creator>
      <dc:date>2007-04-07T09:04:59Z</dc:date>
    </item>
  </channel>
</rss>

