<?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: Changing QVD date Field Values in script in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224023#M867294</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What if Duke has same DB starting from 2001 to 2016 same format. Do we write Pick and match to get those. Can you sort it out&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 08 Dec 2016 01:54:43 GMT</pubDate>
    <dc:creator>Anil_Babu_Samineni</dc:creator>
    <dc:date>2016-12-08T01:54:43Z</dc:date>
    <item>
      <title>Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224019#M867283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;how can I change the date value of a field in my QVD historical file?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I found some anomalies in my data that we're working to resolve, but I don't want to load all the previous tables I have (they are month end tables, and these anomalies occurred awhile ago) and I would like to change their value. Some analysts at my company entered: MM/DD/2106 for the date they were supposed to enter instead of 2016.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Here's what I tried, and it's not working.... any suggestions?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;Pkey&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; = 33479, &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(06/04/2016, 'MM/DD/YYYY')), &lt;/SPAN&gt;&lt;SPAN style="color: #800000; font-size: 8pt;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;I also tried:&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black; font-family: 'Segoe UI',sans-serif; font-size: 10pt;"&gt;if(Pkey = 33479, left(date([Response Due Date],'MM/DD/YYYY'),6)&amp;amp;year(today()),[Response Due Date])&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: black; font-family: 'Segoe UI',sans-serif; font-size: 10pt;"&gt;The date is not changing though. It's still 06/04/2106 when I view in a table box. &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 25 Nov 2020 16:16:04 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224019#M867283</guid>
      <dc:creator>lucasdavis500</dc:creator>
      <dc:date>2020-11-25T16:16:04Z</dc:date>
    </item>
    <item>
      <title>Re: Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224020#M867286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;subtract 90 years&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;if(.......,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Date(AddYears(Date#(&lt;SPAN style="color: #000000; font-family: 'Segoe UI', sans-serif; font-size: 13.3333px;"&gt;[Response Due Date],&lt;/SPAN&gt; 'MM/DD/YYYY'), -90), 'MM/DD/YYYY') ,&lt;/P&gt;&lt;P&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; &lt;SPAN style="color: #000000; font-family: 'Segoe UI', sans-serif; font-size: 13.3333px;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #000000; font-family: 'Segoe UI', sans-serif; font-size: 13.3333px;"&gt;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; ) as &lt;SPAN style="color: #000000; font-family: 'Segoe UI', sans-serif; font-size: 13.3333px;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 07 Dec 2016 22:16:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224020#M867286</guid>
      <dc:creator>maxgro</dc:creator>
      <dc:date>2016-12-07T22:16:36Z</dc:date>
    </item>
    <item>
      <title>Re: Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224021#M867289</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Might be as below:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN class="Code" style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;Replace(&lt;SPAN style="font-size: 13.3333px; font-family: 'Segoe UI', sans-serif; color: #000000;"&gt;[Response Due Date]&lt;/SPAN&gt;,'2106','2016')&lt;/SPAN&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 13px;"&gt; as &lt;SPAN style="color: #000000; font-family: 'Segoe UI', sans-serif; font-size: 13.3333px;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Dec 2016 01:43:23 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224021#M867289</guid>
      <dc:creator>trdandamudi</dc:creator>
      <dc:date>2016-12-08T01:43:23Z</dc:date>
    </item>
    <item>
      <title>Re: Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224022#M867292</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;For first you may missed the Required format&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="font-size: 13px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; color: #3d3d3d;"&gt;&lt;SPAN style="color: #0000ff; font-style: inherit; font-size: 10pt; font-family: inherit; font-weight: inherit;"&gt;if&lt;/SPAN&gt;&lt;SPAN style="font-size: 10pt;"&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #800000;"&gt;Pkey&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt; =&lt;SPAN style="color: #ff0000; font-size: 12pt;"&gt;&lt;STRONG&gt; '&lt;/STRONG&gt;&lt;/SPAN&gt;33479&lt;SPAN style="; color: #ff0000; font-size: 12pt;"&gt;&lt;STRONG&gt;'&lt;/STRONG&gt;&lt;/SPAN&gt; &lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;and &lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #800000;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt; = &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #0000ff;"&gt;date&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #0000ff;"&gt;date#&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt;(&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;MakeDate('&lt;/STRONG&gt;&lt;/SPAN&gt;06/04/2016&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;')&lt;/STRONG&gt;&lt;/SPAN&gt;, 'MM/DD/YYYY'),'&lt;SPAN style="color: #ff0000;"&gt;&lt;STRONG&gt;RequiredDateFormat&lt;/STRONG&gt;&lt;/SPAN&gt;'), &lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit; color: #800000;"&gt;[Response Due Date]&lt;/SPAN&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-family: inherit;"&gt;)&lt;/SPAN&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-weight: inherit; font-style: inherit; font-size: 8pt; font-family: inherit;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-style: inherit; font-size: 10pt; font-family: inherit; font-weight: inherit;"&gt;&lt;STRONG style="text-decoration: underline;"&gt;Note:&lt;/STRONG&gt; And Finally, I would read this to change before transformation. I mean, please change DB and then again store into Qvd then load to the QlikView. &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-style: inherit; font-size: 10pt; font-family: inherit; font-weight: inherit;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-style: inherit; font-size: 10pt; font-family: inherit; font-weight: inherit;"&gt;Then, It showing lot make sense Or else you may get trouble with the punch of Year&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Dec 2016 01:48:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224022#M867292</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-12-08T01:48:36Z</dc:date>
    </item>
    <item>
      <title>Re: Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224023#M867294</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;What if Duke has same DB starting from 2001 to 2016 same format. Do we write Pick and match to get those. Can you sort it out&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Dec 2016 01:54:43 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224023#M867294</guid>
      <dc:creator>Anil_Babu_Samineni</dc:creator>
      <dc:date>2016-12-08T01:54:43Z</dc:date>
    </item>
    <item>
      <title>Re: Changing QVD date Field Values in script</title>
      <link>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224024#M867295</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Based on his question, I think the date is entered wrong only for the PKey=33479 and he wants to do this change on the script side. We can achieve this by simply using Preceding load like below:&lt;/P&gt;&lt;P&gt;&lt;SPAN style="text-decoration: underline;"&gt;&lt;STRONG&gt;Option I&lt;/STRONG&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;Pkey,&lt;/P&gt;&lt;P&gt;IF (Pkey=33479,Replace(Response_Due_Date,2106,2016),Response_Due_Date) as Response_Due_Date;&lt;/P&gt;&lt;P&gt;Load * Inline [&lt;/P&gt;&lt;P&gt;Pkey,Response_Due_Date&lt;/P&gt;&lt;P&gt;33479,6/04/2106&lt;/P&gt;&lt;P&gt;33478,6/04/2016&lt;/P&gt;&lt;P&gt;33476,7/04/2016&lt;/P&gt;&lt;P&gt;] ;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regardless of the Pkey, if he wants to change the year part from 2106 to 2016 then he can use the below Option II :&lt;/P&gt;&lt;P&gt;&lt;STRONG style="text-decoration: underline;"&gt;Option II&lt;/STRONG&gt;&lt;/P&gt;&lt;P&gt;Data:&lt;/P&gt;&lt;P&gt;Load&lt;/P&gt;&lt;P&gt;Pkey,&lt;/P&gt;&lt;P&gt;Replace(Response_Due_Date,2106,2016) as Response_Due_Date;&lt;/P&gt;&lt;P&gt;Load * Inline [&lt;/P&gt;&lt;P&gt;Pkey,Response_Due_Date&lt;/P&gt;&lt;P&gt;33479,6/04/2106&lt;/P&gt;&lt;P&gt;33478,6/04/2016&lt;/P&gt;&lt;P&gt;33476,7/04/2016&lt;/P&gt;&lt;P&gt;];&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Note: Make sure you adjust the date formats according to your needs. By just adding the preceding load, it is simple and easy for maintenance rather then troubleshooting whole code.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 08 Dec 2016 02:55:13 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Changing-QVD-date-Field-Values-in-script/m-p/1224024#M867295</guid>
      <dc:creator>trdandamudi</dc:creator>
      <dc:date>2016-12-08T02:55:13Z</dc:date>
    </item>
  </channel>
</rss>

