<?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: Adding month to the Variable in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188969#M384323</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When i use same piece code it doesn't seem to be working here. I am getting now in filecodemax column not sure why. Also not sure why the value in the filename is prefixed with 00640100250.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Wed, 21 Sep 2016 07:14:18 GMT</pubDate>
    <dc:creator>qlikviewforum</dc:creator>
    <dc:date>2016-09-21T07:14:18Z</dc:date>
    <item>
      <title>Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188966#M384320</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I have a variable called zDates='2016_07'. I need to check whether QVD's with the date already exists in appropriate location or not.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Name of the QVD will be as below. &lt;/P&gt;&lt;P&gt;Employee_M.2016_05.qvd&lt;BR /&gt;Employee_M.2016_06.qvd&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In this case since 2016_07 qvd does not exists in the file system I need to add that date to the variable. So the variable now should have zDates='2016_07','2016_06'.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the value in the variable is zDates='2016_06' then there wont be any changes in the varaible it will remain same. That is zDates='2016_06'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the file system contains below qvd's and the variable zDates='2016_01' then in that case the variable should be updated to zDates='2015_12',2016_01'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Employee_M.2016_11.qvd&lt;/P&gt;&lt;P&gt;Employee_M.2016_12.qvd&lt;/P&gt;&lt;P&gt;&lt;BR /&gt;Can someone help me to achieve this?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 20 Sep 2016 17:59:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188966#M384320</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-20T17:59:41Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188967#M384321</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;In short below is what I need. Can anyone help me out on this? As this is very urgent.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;If the value in the variable is 2016_07 and if 2016_07 qvd doesn't exists then I should add 2016_06 to the variable.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;If the value in the variable is 2016_07 and if 2016_07 qvd&amp;nbsp; exists then I should not anything to the variable.&lt;/SPAN&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;if the value in the variable is 2016_01 and 2016_01 doesnt exists then I should add 2015_12 to the variable.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;if the value in the variable is 2016_01 and 2016_01 exists then I should not add anything to the variable.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Calibri; font-size: 12pt;"&gt;Please let me know if you have any questions.&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: Times New Roman; font-size: 12pt;"&gt;&amp;nbsp; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 06:11:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188967#M384321</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T06:11:21Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188968#M384322</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The steps I would take are:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;1- Scan all files and load the filenames (this code is easily found on here)&lt;/P&gt;&lt;P&gt;2- figure out the numeric code of the filename&lt;/P&gt;&lt;P&gt;3- Then apply your logic from that&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;something like this, you can tweak the logic to be what you want&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//loop through files and load filenames&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;for each File1 in filelist ('c:\blah\*.qvd')&lt;/P&gt;&lt;P&gt;files:&lt;/P&gt;&lt;P&gt;LOAD keepchar(filename,0123456789) as filecode;&lt;/P&gt;&lt;P&gt;LOAD&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; '$(File1)' as filename&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; AUTOGENERATE 1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;NEXT File1;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//now pull the max filename from the list&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;MAX:&lt;/P&gt;&lt;P&gt;LOAD max(filecode) as filecodemax&lt;/P&gt;&lt;P&gt;RESIDENT files;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//drop the table we don't need anymore&lt;/P&gt;&lt;P&gt;DROP TABLE files;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//set our test variable to be the max value&lt;/P&gt;&lt;P&gt;LET zTest = FieldValue('filecodemax',1);&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;//do the test&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;let zDates = if(replace('$(zDates)','_','') = $(zTest), //is the max value equal to existing variable?&lt;/P&gt;&lt;P&gt;&amp;nbsp; left('$(zDates)',4)&amp;amp;'_'&amp;amp;right('$(zDates)',2), //if so then leave it alone&lt;/P&gt;&lt;P&gt;&amp;nbsp; left($(zTest),4)&amp;amp;'_'&amp;amp;right($(zTest),2)); //otherwise set to max value&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Menlo, Monaco, Consolas, 'Courier New', monospace; font-size: 13px; letter-spacing: 0.5px; white-space: pre-wrap; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Menlo, Monaco, Consolas, 'Courier New', monospace; font-size: 13px; letter-spacing: 0.5px; white-space: pre-wrap; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="color: #000000; font-family: Menlo, Monaco, Consolas, 'Courier New', monospace; font-size: 13px; letter-spacing: 0.5px; white-space: pre-wrap; background-color: #ffffff;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;DIV&gt;&lt;SPAN style="letter-spacing: 0.5px; color: #000000; font-size: 13.3333px; white-space: pre-wrap; background-color: #ffffff; font-family: Menlo, Monaco, Consolas, 'Courier New', monospace;"&gt;&lt;EM&gt;Please remember to mark this as helpful or the correct answer if I have helped you or answered your question.&lt;/EM&gt;&lt;/SPAN&gt;&lt;/DIV&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 06:46:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188968#M384322</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T06:46:20Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188969#M384323</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;When i use same piece code it doesn't seem to be working here. I am getting now in filecodemax column not sure why. Also not sure why the value in the filename is prefixed with 00640100250.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:14:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188969#M384323</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:14:18Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188970#M384324</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I think you'll have to provide some more information.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Can you provide the exact names of your qvd files as I tested with the ones you gave and it seemed to work fine&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:17:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188970#M384324</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T07:17:29Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188971#M384325</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;CVAR_M.2016_01.qvd this is the fine name. Can check with this?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:22:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188971#M384325</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:22:41Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188972#M384326</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;hmm seems to run OK for me:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt; files:&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0028&amp;nbsp;&amp;nbsp; LOAD keepchar(filename,0123456789) as filecode&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0029&amp;nbsp;&amp;nbsp; LOAD&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0030&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'c:\blah\CVAR_M.2016_01.qvd' as filename&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0031&amp;nbsp;&amp;nbsp;&amp;nbsp; AUTOGENERATE 1&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 fields found: filecode, &lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 lines fetched&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0033 NEXT File1&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0027&amp;nbsp;&amp;nbsp; files:&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0028&amp;nbsp;&amp;nbsp; LOAD keepchar(filename,0123456789) as filecode&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0029&amp;nbsp;&amp;nbsp; LOAD&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0030&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 'c:\blah\CVAR_M.2016_02.qvd' as filename&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0031&amp;nbsp;&amp;nbsp;&amp;nbsp; AUTOGENERATE 1&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 fields found: filecode, &lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 2 lines fetched&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0033 NEXT File1&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0037 MAX:&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0038 LOAD max(filecode) as filecodemax&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0039 RESIDENT files&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 fields found: filecodemax, &lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; 1 lines fetched&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0042 DROP TABLE files&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0045 LET zTest = FieldValue('filecodemax',1)&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0049 let zDates = if(replace('2016_01','_','') = 201602,&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0050 left('2016_01',4)&amp;amp;'_'&amp;amp;right('2016_01',2),&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37 0051 left(201602,4)&amp;amp;'_'&amp;amp;right(201602,2))&lt;/P&gt;&lt;P&gt;2016-09-21 08:25:37&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Execution finished.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:26:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188972#M384326</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T07:26:36Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188973#M384327</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;I got the issue below numbers existing in the physical file path so it is fetching those numbers as well.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any idea how can I avoid this?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:29:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188973#M384327</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:29:10Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188974#M384328</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;We need to use right('$(File1)',6) as filename. Will check and let you know.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:31:30 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188974#M384328</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:31:30Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188975#M384329</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;sorry I think we need to use right(keepchar(filename,0123456789),6). I will check and let you know.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:36:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188975#M384329</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:36:36Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188976#M384330</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Cool, hopefully you can just tweak that code until it works!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:41:09 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188976#M384330</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T07:41:09Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188977#M384331</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yes I am trying to do that. But I am getting the below error not sure why.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Script line error: &lt;/P&gt;&lt;P&gt;let zSecondLoadDates = if(replace('''2016_07'',''2016_09''','_','') = 201607,left('''2016_07'',''2016_09''',4)&amp;amp;'_'&amp;amp;right('''2016_07'',''2016_09''',2),&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; left(201607,4)&amp;amp;'_'&amp;amp;right(201607,2))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I think value in the variable is something like below&lt;/P&gt;&lt;P&gt; zSecondLoadDates='2016_07'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Any idea how this can be handled?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:50:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188977#M384331</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:50:55Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188978#M384332</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hmmm so the variable includes the ' already?&lt;/P&gt;&lt;P&gt;if so then take that out of the replace statement so&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;if(replace(&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;'&lt;/STRONG&gt;&lt;/SPAN&gt;$(zDates)&lt;SPAN style="color: #ff6600;"&gt;&lt;STRONG&gt;'&lt;/STRONG&gt;&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; font-size: 13px;"&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; font-size: 13px;"&gt;becomes&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;if(replace($(zDates),'_','')&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 13px; 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-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;It looks like you just have too many ' going on!&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:56:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188978#M384332</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T07:56:00Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188979#M384333</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The variable already contains value like below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;zSecondLoadDates='2016_07'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;If the new date has to be added then it should be something like below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;zSecondLoadDates='2016_07','2016_06'&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Not sure how this can be handled &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/sad.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:56:08 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188979#M384333</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:56:08Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188980#M384334</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;it tried doing this but it didn't work.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Yes too many thing going on. Not been able to focus &lt;IMG src="https://community.qlik.com/legacyfs/online/emoticons/cry.png" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 07:58:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188980#M384334</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T07:58:39Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188981#M384335</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry I think I had two values in zSecondLoadDates='2016_07','2016_09' so it was getting failed.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 08:07:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188981#M384335</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T08:07:57Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188982#M384336</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;ahhhh yes I can see that now in your error, sorry I am not awake yet!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 08:09:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188982#M384336</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T08:09:23Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188983#M384337</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry this didn't work either&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 08:09:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188983#M384337</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T08:09:59Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188984#M384338</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Sorry to disturb you. Please check if you can help on this as it is very urgent.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 08:10:56 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188984#M384338</guid>
      <dc:creator>qlikviewforum</dc:creator>
      <dc:date>2016-09-21T08:10:56Z</dc:date>
    </item>
    <item>
      <title>Re: Adding month to the Variable</title>
      <link>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188985#M384339</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;what error do you get now you only have one item in the variable?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 21 Sep 2016 08:12:18 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Adding-month-to-the-Variable/m-p/1188985#M384339</guid>
      <dc:creator>adamdavi3s</dc:creator>
      <dc:date>2016-09-21T08:12:18Z</dc:date>
    </item>
  </channel>
</rss>

