<?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 Problems using indexw functions in SAS Procedures</title>
    <link>https://communities.sas.com/t5/SAS-Procedures/Problems-using-indexw-functions/m-p/194514#M48812</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;I have a problem with indexw function. I don't know what, but this code desont' worl properly:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data ruta;&lt;/P&gt;&lt;P&gt;ruta = "O:\_Privada\JVidal\Proyecto base\proyecto base.egp";&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data ruta_1;&lt;/P&gt;&lt;P&gt;set ruta;&lt;/P&gt;&lt;P&gt;nomfich=scan(ruta,-1,'\');&lt;/P&gt;&lt;P&gt;pos1 = indexw(ruta, nomfich);&lt;/P&gt;&lt;P&gt;pos2 = indexw(ruta, 'proyecto');&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The result is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="indexw.png" class="jive-image-thumbnail jive-image" src="https://communities.sas.com/legacyfs/online/10633_indexw.png" width="450" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody help me?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://sasybi.blogspot.com"&gt;http://sasybi.blogspot.com&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 27 May 2015 21:59:21 GMT</pubDate>
    <dc:creator>juanvg1972</dc:creator>
    <dc:date>2015-05-27T21:59:21Z</dc:date>
    <item>
      <title>Problems using indexw functions</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Problems-using-indexw-functions/m-p/194514#M48812</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;I have a problem with indexw function. I don't know what, but this code desont' worl properly:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data ruta;&lt;/P&gt;&lt;P&gt;ruta = "O:\_Privada\JVidal\Proyecto base\proyecto base.egp";&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;data ruta_1;&lt;/P&gt;&lt;P&gt;set ruta;&lt;/P&gt;&lt;P&gt;nomfich=scan(ruta,-1,'\');&lt;/P&gt;&lt;P&gt;pos1 = indexw(ruta, nomfich);&lt;/P&gt;&lt;P&gt;pos2 = indexw(ruta, 'proyecto');&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The result is:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;IMG alt="indexw.png" class="jive-image-thumbnail jive-image" src="https://communities.sas.com/legacyfs/online/10633_indexw.png" width="450" /&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can anybody help me?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks in advance&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;A class="jive-link-external-small" href="http://sasybi.blogspot.com"&gt;http://sasybi.blogspot.com&lt;/A&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 May 2015 21:59:21 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Problems-using-indexw-functions/m-p/194514#M48812</guid>
      <dc:creator>juanvg1972</dc:creator>
      <dc:date>2015-05-27T21:59:21Z</dc:date>
    </item>
    <item>
      <title>Re: Problems using indexw functions</title>
      <link>https://communities.sas.com/t5/SAS-Procedures/Problems-using-indexw-functions/m-p/194515#M48813</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In the future please describe how "it doesn't work", unexpected output and the expected result, no output or error messages.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;With that, is this what you may have been looking for:&lt;/P&gt;&lt;P&gt;data work.ruta_1;&lt;/P&gt;&lt;P&gt;ruta = "O:\_Privada\JVidal\Proyecto base\proyecto base.egp";&lt;/P&gt;&lt;P&gt;nomfich=scan(ruta,-1,'\');&lt;/P&gt;&lt;P&gt;pos1 = indexw(ruta,strip(nomfich),'\.');&lt;/P&gt;&lt;P&gt;pos2 = indexw(ruta, 'proyecto','\ ');&lt;/P&gt;&lt;P&gt;run;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;pos1 = indexw(ruta,strip(nomfich),'\.'); Needs to have blanks removed. If you look at the properties of the variable NOMFICH you will see that it is 200 characters long. The blanks at the end are included in comparisons unless removed for the operation. ALSO you need to provide information that \ is a word boundary character.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 27 May 2015 22:28:39 GMT</pubDate>
      <guid>https://communities.sas.com/t5/SAS-Procedures/Problems-using-indexw-functions/m-p/194515#M48813</guid>
      <dc:creator>ballardw</dc:creator>
      <dc:date>2015-05-27T22:28:39Z</dc:date>
    </item>
  </channel>
</rss>

