<?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: Cannot get Qlik Sense to convert SQL Timestamp in App Development</title>
    <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107988#M90487</link>
    <description>&lt;P&gt;Hi, perform the conversion in a preceding load, above the SELECT statement like this.&lt;/P&gt;
&lt;P&gt;LOAD Id as [Alert ID], &lt;BR /&gt;Timestamp(Timestamp#(TimeRaised ,'YYYY-MM-DD hh:mm:ss.fffffff'),'YYYY-MMM-DD hh:mm:ss TT') as [Alert Time Raised];&lt;/P&gt;
&lt;P&gt;SQL SELECT &lt;BR /&gt;Id, &lt;BR /&gt;TimeRaised &lt;BR /&gt;From xyz;&lt;/P&gt;</description>
    <pubDate>Mon, 21 Aug 2023 20:51:57 GMT</pubDate>
    <dc:creator>BrunPierre</dc:creator>
    <dc:date>2023-08-21T20:51:57Z</dc:date>
    <item>
      <title>Cannot get Qlik Sense to convert SQL Timestamp</title>
      <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107977#M90484</link>
      <description>&lt;P&gt;Hi Folks&amp;nbsp;&lt;/P&gt;
&lt;P&gt;I have a direct connection to a SQL database for a basic select statement:&lt;/P&gt;
&lt;DIV&gt;SQL SELECT&amp;nbsp;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;&amp;nbsp; Id as [Alert ID],&amp;nbsp;&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;SPAN&gt;&amp;nbsp;TimeRaised AS [Alert Time Raised]&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;From xyz&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;The timestamp returned is like this (Year-Month-Day Time):&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;2023-08-18 18:00:08.907000&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;I need the format to be 2023-Aug-18 18:00 PM&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;I set the Time Format like this&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;SET TimestampFormat='YYYY-MM-DD hh:mm:ss tt';&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;But Qlik Sense is not recognizing the incoming timestamp and does not convert it like I need.&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Be grateful for any advice.&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Thanks&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&lt;SPAN&gt;Nigel&lt;/SPAN&gt;&lt;/DIV&gt;
&lt;DIV&gt;&amp;nbsp;&lt;/DIV&gt;</description>
      <pubDate>Mon, 21 Aug 2023 19:53:36 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107977#M90484</guid>
      <dc:creator>nigelapthome</dc:creator>
      <dc:date>2023-08-21T19:53:36Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot get Qlik Sense to convert SQL Timestamp</title>
      <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107978#M90485</link>
      <description>&lt;P&gt;Hi&amp;nbsp;&lt;a href="https://community.qlik.com/t5/user/viewprofilepage/user-id/192380"&gt;@nigelapthome&lt;/a&gt;&amp;nbsp;&lt;/P&gt;
&lt;P&gt;Have you tried using the Timestamp Function ?&lt;/P&gt;
&lt;P&gt;Since you already changed the format on the Set variable, simply using &lt;STRONG&gt;Timestamp(&lt;/STRONG&gt;&lt;SPAN&gt;&lt;STRONG&gt;TimeRaised)&lt;/STRONG&gt; AS [Alert Time Raised]&lt;/SPAN&gt;) should work.&lt;/P&gt;
&lt;P&gt;Let me know if it helps.&lt;/P&gt;
&lt;P&gt;-Zapparoli&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 19:58:05 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107978#M90485</guid>
      <dc:creator>Zapparoli</dc:creator>
      <dc:date>2023-08-21T19:58:05Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot get Qlik Sense to convert SQL Timestamp</title>
      <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107988#M90487</link>
      <description>&lt;P&gt;Hi, perform the conversion in a preceding load, above the SELECT statement like this.&lt;/P&gt;
&lt;P&gt;LOAD Id as [Alert ID], &lt;BR /&gt;Timestamp(Timestamp#(TimeRaised ,'YYYY-MM-DD hh:mm:ss.fffffff'),'YYYY-MMM-DD hh:mm:ss TT') as [Alert Time Raised];&lt;/P&gt;
&lt;P&gt;SQL SELECT &lt;BR /&gt;Id, &lt;BR /&gt;TimeRaised &lt;BR /&gt;From xyz;&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 20:51:57 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2107988#M90487</guid>
      <dc:creator>BrunPierre</dc:creator>
      <dc:date>2023-08-21T20:51:57Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot get Qlik Sense to convert SQL Timestamp</title>
      <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2108008#M90488</link>
      <description>&lt;P&gt;No luck Matheus&lt;/P&gt;
&lt;P&gt;It is not seeing the SQL date as a date format.&lt;/P&gt;
&lt;P&gt;I also tried changing the format in SQL :&lt;/P&gt;
&lt;P&gt;Convert(varchar,TimeRaised,20) AS [Alert Time Raised]&lt;/P&gt;
&lt;P&gt;Running it in SQL Server Management gives this format:&lt;/P&gt;
&lt;P&gt;2023-08-20 00:28:15 (YYYY-MM-DD HH:MM:SS)&lt;/P&gt;
&lt;P&gt;but again QlikSense does not see to accept this.&lt;/P&gt;</description>
      <pubDate>Mon, 21 Aug 2023 21:16:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2108008#M90488</guid>
      <dc:creator>nigelapthome</dc:creator>
      <dc:date>2023-08-21T21:16:19Z</dc:date>
    </item>
    <item>
      <title>Re: Cannot get Qlik Sense to convert SQL Timestamp</title>
      <link>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2108239#M90498</link>
      <description>&lt;P&gt;Each inbuilt conversion will only work if the applied format-pattern fits to 100% to the data. To get this data you need to load them as they are into Qlik (and only these data - if you had loaded any values into this field within a previous load - it could have an impact) and then using a table-box to look at them and/or to export it to an editor like Notepad++. Also possible is to loop within the script though each single char to track their value.&lt;/P&gt;
&lt;P&gt;Looking at the values within the data-base may trick you because they mustn't show the stored values else any conversion/formatting. Further the used driver could apply any change to the data.&lt;/P&gt;
&lt;P&gt;Beside of this you may also consider a bit tedious approach by using string-functions like keepchar(), trim(), subfield(), ... to cut the date- and time-parts and converting/formatting those results.&lt;/P&gt;</description>
      <pubDate>Tue, 22 Aug 2023 07:18:42 GMT</pubDate>
      <guid>https://community.qlik.com/t5/App-Development/Cannot-get-Qlik-Sense-to-convert-SQL-Timestamp/m-p/2108239#M90498</guid>
      <dc:creator>marcus_sommer</dc:creator>
      <dc:date>2023-08-22T07:18:42Z</dc:date>
    </item>
  </channel>
</rss>

