<?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: Extract sub folder name from a full file path in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543601#M686931</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try&lt;/P&gt;&lt;P&gt;subfield('&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;C:\decisioning\log\dcs\&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #ff0000;"&gt;1&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;\1\dcs_meta_data_20131126113434.csv&lt;/SPAN&gt;','\',-3) will return the second last directory&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 02 Jan 2014 11:02:51 GMT</pubDate>
    <dc:creator>Clever_Anjos</dc:creator>
    <dc:date>2014-01-02T11:02:51Z</dc:date>
    <item>
      <title>Extract sub folder name from a full file path</title>
      <link>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543598#M686928</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;This is an example for a path that I have:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;C:\decisioning\log\dcs\&lt;SPAN style="color: #ff0000;"&gt;1&lt;/SPAN&gt;\1\dcs_meta_data_20131126113434.csv&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;I need to compare the folder number highlighted in &lt;SPAN style="color: #ff0000;"&gt;RED&lt;/SPAN&gt; &lt;SPAN style="color: #000000;"&gt;to a list.&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;how can I isolate the folder number?&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;I had a code written with FileName function but I know it doesn't work in regular script but only in load script.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;regards,&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;Boris&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jan 2014 09:47:54 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543598#M686928</guid>
      <dc:creator />
      <dc:date>2014-01-02T09:47:54Z</dc:date>
    </item>
    <item>
      <title>Re: Extract sub folder name from a full file path</title>
      <link>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543599#M686929</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I am not sure if i understood your question, but, are you trying to achieve this in the expression or you are trying in the load script.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If in load script, you can use the subfield syntax to get the string.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Aadil&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jan 2014 10:29:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543599#M686929</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-01-02T10:29:22Z</dc:date>
    </item>
    <item>
      <title>Re: Extract sub folder name from a full file path</title>
      <link>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543600#M686930</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P class="Code"&gt;Load *, filedir( ) as X from&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P class="Code"&gt;C:\UserFiles\abc.txt&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Will return 'C:\UserFiles' in field X in each &lt;BR /&gt;record read. &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;So you could use:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;load subfield(filedir(),'\',5) as FolderNumber&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Hope that helps!&lt;/P&gt;&lt;P&gt;regards.janne&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jan 2014 10:59:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543600#M686930</guid>
      <dc:creator>mr_janne</dc:creator>
      <dc:date>2014-01-02T10:59:58Z</dc:date>
    </item>
    <item>
      <title>Re: Extract sub folder name from a full file path</title>
      <link>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543601#M686931</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;try&lt;/P&gt;&lt;P&gt;subfield('&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;C:\decisioning\log\dcs\&lt;/SPAN&gt;&lt;SPAN style="font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #ff0000;"&gt;1&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;\1\dcs_meta_data_20131126113434.csv&lt;/SPAN&gt;','\',-3) will return the second last directory&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 02 Jan 2014 11:02:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Extract-sub-folder-name-from-a-full-file-path/m-p/543601#M686931</guid>
      <dc:creator>Clever_Anjos</dc:creator>
      <dc:date>2014-01-02T11:02:51Z</dc:date>
    </item>
  </channel>
</rss>

