<?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 AW:Re: Help formatting time in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320279#M1197286</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roland!&lt;/P&gt;&lt;P&gt;This was &lt;B&gt;exactly&lt;/B&gt; what I wanted but didn't know how to do.&lt;BR /&gt;Thank you very much! &lt;IMG alt="Smile" src="http://community.qlik.com/emoticons/emotion-1.gif" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Mon, 11 Apr 2011 18:46:53 GMT</pubDate>
    <dc:creator>qw_johan</dc:creator>
    <dc:date>2011-04-11T18:46:53Z</dc:date>
    <item>
      <title>Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320274#M1197281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;I am loading a textfile that has a "time_duration" field. Unfortunately all the time data isn't formatted the same way.&lt;BR /&gt;The "time" can be formatted both like "1 min 32 sec" and like just "97" (meaning 97 seconds) .&lt;BR /&gt;How can I handle this in Qlikview? I would like all data in that field to be displayed the same minutes and seconds.&lt;/P&gt;&lt;P&gt;I have been trying to use time() and time#() without success.&lt;/P&gt;&lt;P&gt;Thanks&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 14:44:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320274#M1197281</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-04-11T14:44:11Z</dc:date>
    </item>
    <item>
      <title>Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320275#M1197282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi,&lt;/P&gt;&lt;P&gt;Could you please post few rows of sample data from the text file?&lt;/P&gt;&lt;P&gt;Regards,&lt;/P&gt;&lt;P&gt;Murali&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 14:47:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320275#M1197282</guid>
      <dc:creator />
      <dc:date>2011-04-11T14:47:22Z</dc:date>
    </item>
    <item>
      <title>Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320276#M1197283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Murali!&lt;/P&gt;&lt;P&gt;Here are some sample data. The data in &lt;I&gt;time_duration&lt;/I&gt; field is formatted in two different ways. How can I make it same?&lt;BR /&gt;I have tried time() function with no success. Also tried this...&lt;BR /&gt;//If time_duration string doesn't have "min" in it then convert the data&lt;BR /&gt;if(FindOneOf(time_duration, 'min')=0, Time(Time#(time_duration,'ss'),'hh:mm:ss'), time_duration) as time_duration&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;type number &lt;B&gt;time_duration&lt;/B&gt;&lt;/P&gt;&lt;P&gt;09FB 184461 &lt;B&gt;1 min 16 sec&lt;/B&gt;&lt;/P&gt;&lt;P&gt;09FB 895299 &lt;B&gt;88&lt;/B&gt; --&amp;gt; 1 min 28 sec&lt;/P&gt;&lt;P&gt;09FB 184461 &lt;B&gt;97&lt;/B&gt; --&amp;gt; 1 min 37 sec&lt;/P&gt;&lt;P&gt;09FB 184461 &lt;B&gt;2 min 34 sec&lt;/B&gt;&lt;/P&gt;&lt;P&gt;09FC 467018 &lt;B&gt;233&lt;/B&gt; --&amp;gt; 3 min 53 sec&lt;/P&gt;&lt;P&gt;09FB 467378 &lt;B&gt;0 min 16 sec&lt;/B&gt;&lt;/P&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 16:35:29 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320276#M1197283</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-04-11T16:35:29Z</dc:date>
    </item>
    <item>
      <title>AW:Re: Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320277#M1197284</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello qw_johan,&lt;/P&gt;&lt;P&gt;I am not sure if you can achieve it using the time-functions. I would try something like that (assuming you don't have hours, but this should be an easy add-on then):&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;if(FindOneOf(time_duration, 'min')=0, &lt;I&gt;floor(time_duration/ 60) &amp;amp; ' min ' &amp;amp; Mod( time_duration, 60) &amp;amp; ' sec'&lt;/I&gt;, time_duration)&lt;BR /&gt;as time_duration&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;Regards, Roland&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 17:43:24 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320277#M1197284</guid>
      <dc:creator />
      <dc:date>2011-04-11T17:43:24Z</dc:date>
    </item>
    <item>
      <title>AW:Re: Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320278#M1197285</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Have a look what i wanted to try :&lt;/P&gt;&lt;P style="margin-bottom:0.0001pt;line-height:normal;"&gt;&lt;/P&gt;&lt;BLOCKQUOTE style="overflow-x: scroll;"&gt;&lt;PRE style="margin: 0px;"&gt;&lt;I&gt;Orig_table:&lt;/I&gt;&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;&lt;B&gt;Load&lt;/B&gt; * &lt;B&gt;Inline&lt;/B&gt; [&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;//your sample data&lt;BR /&gt;&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;;&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;&lt;I&gt;Transformed:&lt;/I&gt;&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;&lt;B&gt;Load&lt;/B&gt; *,&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;Time(Time#(If(Isnum(Time_duration),Time_duration,Num#(SubField(Time_duration,' ',1))*60 +Num#(Subfield(Time_duration,' ',3),'#') ),'s'),'mm:ss') &lt;B&gt;as&lt;/B&gt; Time,&lt;BR style="margin-bottom:0.0001pt;line-height:normal;" /&gt;&lt;B&gt;resident&lt;/B&gt; Orig_table;&lt;BR /&gt;&lt;B&gt;drop&lt;/B&gt; &lt;B&gt;Table&lt;/B&gt; &lt;I&gt;Orig_table;&lt;/I&gt;&lt;BR /&gt;&lt;/PRE&gt;&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt; &lt;P&gt;you can use the exactly same format of expression depending on your data (if it does not vary in format from what you exactly gave in sample data).&lt;/P&gt;&lt;P&gt;Hope this helps.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Regards, tresesco&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 18:17:17 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320278#M1197285</guid>
      <dc:creator>tresB</dc:creator>
      <dc:date>2011-04-11T18:17:17Z</dc:date>
    </item>
    <item>
      <title>AW:Re: Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320279#M1197286</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Roland!&lt;/P&gt;&lt;P&gt;This was &lt;B&gt;exactly&lt;/B&gt; what I wanted but didn't know how to do.&lt;BR /&gt;Thank you very much! &lt;IMG alt="Smile" src="http://community.qlik.com/emoticons/emotion-1.gif" /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 18:46:53 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320279#M1197286</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-04-11T18:46:53Z</dc:date>
    </item>
    <item>
      <title>AW:Re: Help formatting time</title>
      <link>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320280#M1197287</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi tresesco!&lt;/P&gt;&lt;P&gt;Thank you very much for your help. &lt;IMG alt="Smile" src="http://community.qlik.com/emoticons/emotion-1.gif" /&gt;&lt;BR /&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 11 Apr 2011 18:50:12 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Help-formatting-time/m-p/320280#M1197287</guid>
      <dc:creator>qw_johan</dc:creator>
      <dc:date>2011-04-11T18:50:12Z</dc:date>
    </item>
  </channel>
</rss>

