<?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 Possible bug ? Changing field name changes format in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885849#M72965</link>
    <description>&lt;P&gt;I get a date in a strange format.&lt;/P&gt;
&lt;P&gt;1YYMMDD, One would assume that the following will work fine.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Date(Date#(right(datefield,6),'YYMMDD')) as [DateField Check],&lt;BR /&gt;Result : 2021/01/27&lt;BR /&gt;&lt;BR /&gt;This worked fine and gave the results as expected. A date value in the format as specefied in the main sheet.&amp;nbsp; However now that I have tested this and it is working I wanted to change the name to the correct one, so all I did was alter the code to be the following&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Date(Date#(right(datefield,6),'YYMMDD')) as [DateField],&lt;BR /&gt;Result : 44557&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Now it changes from a date format to a number ??&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have also tried to specify the date format by using&amp;nbsp;&lt;BR /&gt;Date(Date#(right(datefield,6),'YYMMDD'),'YYYY/MM/DD') as [DateField],&lt;BR /&gt;Still the same error.&lt;BR /&gt;&lt;BR /&gt;What could be causing this.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
    <pubDate>Thu, 27 Jan 2022 07:43:15 GMT</pubDate>
    <dc:creator>JeanJordaan</dc:creator>
    <dc:date>2022-01-27T07:43:15Z</dc:date>
    <item>
      <title>Possible bug ? Changing field name changes format</title>
      <link>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885849#M72965</link>
      <description>&lt;P&gt;I get a date in a strange format.&lt;/P&gt;
&lt;P&gt;1YYMMDD, One would assume that the following will work fine.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Date(Date#(right(datefield,6),'YYMMDD')) as [DateField Check],&lt;BR /&gt;Result : 2021/01/27&lt;BR /&gt;&lt;BR /&gt;This worked fine and gave the results as expected. A date value in the format as specefied in the main sheet.&amp;nbsp; However now that I have tested this and it is working I wanted to change the name to the correct one, so all I did was alter the code to be the following&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;Date(Date#(right(datefield,6),'YYMMDD')) as [DateField],&lt;BR /&gt;Result : 44557&lt;/P&gt;
&lt;P&gt;&lt;BR /&gt;Now it changes from a date format to a number ??&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;I have also tried to specify the date format by using&amp;nbsp;&lt;BR /&gt;Date(Date#(right(datefield,6),'YYMMDD'),'YYYY/MM/DD') as [DateField],&lt;BR /&gt;Still the same error.&lt;BR /&gt;&lt;BR /&gt;What could be causing this.&amp;nbsp;&lt;BR /&gt;&lt;BR /&gt;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jan 2022 07:43:15 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885849#M72965</guid>
      <dc:creator>JeanJordaan</dc:creator>
      <dc:date>2022-01-27T07:43:15Z</dc:date>
    </item>
    <item>
      <title>Re: Possible bug ? Changing field name changes format</title>
      <link>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885861#M72966</link>
      <description>&lt;P&gt;Most likely it is caused by the usage of a field called [DateField] earlier in the script. When this field is loaded, its symbol tables are created, and thus also its format.&lt;/P&gt;&lt;P&gt;So when you load a second instance of the same field, the format of the field value of the first instance is used: The same value of the same field cannot have two different formats.&lt;/P&gt;&lt;P&gt;How to solve it? There are several ways:&lt;BR /&gt;1) Change the script so that you don't use a field called [DateField] earlier in the script. Call it something else.&lt;BR /&gt;2) Drop the earlier field before the second instance is loaded.&lt;BR /&gt;3) Format the first field the way you want it.&lt;/P&gt;&lt;P&gt;Further reading:&lt;BR /&gt;&lt;A href="https://community.qlik.com/t5/Qlik-Design-Blog/Symbol-Tables-and-Bit-Stuffed-Pointers/ba-p/1475369" target="_blank"&gt;https://community.qlik.com/t5/Qlik-Design-Blog/Symbol-Tables-and-Bit-Stuffed-Pointers/ba-p/1475369&lt;/A&gt;&lt;BR /&gt;&lt;A href="https://community.qlik.com/t5/Qlik-Design-Blog/Data-Types-in-QlikView/ba-p/1474977" target="_blank"&gt;https://community.qlik.com/t5/Qlik-Design-Blog/Data-Types-in-QlikView/ba-p/1474977&lt;/A&gt;&lt;/P&gt;&lt;P&gt;HIC&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jan 2022 08:16:16 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885861#M72966</guid>
      <dc:creator>hic</dc:creator>
      <dc:date>2022-01-27T08:16:16Z</dc:date>
    </item>
    <item>
      <title>Re: Possible bug ? Changing field name changes format</title>
      <link>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885870#M72967</link>
      <description>&lt;P&gt;Thank you.&amp;nbsp;&lt;BR /&gt;That was the issue, I updated the code a little and now it all works perfectly.&amp;nbsp;&lt;/P&gt;
&lt;P&gt;&amp;nbsp;&lt;/P&gt;</description>
      <pubDate>Thu, 27 Jan 2022 08:36:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Possible-bug-Changing-field-name-changes-format/m-p/1885870#M72967</guid>
      <dc:creator>JeanJordaan</dc:creator>
      <dc:date>2022-01-27T08:36:24Z</dc:date>
    </item>
  </channel>
</rss>

