<?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 Creating History table in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144318#M23280</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Problem : Show Orders History&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;I have Orders table with Fields of Order_Item_Num,Order_Num,Order_Date,Order_Item_Quantity,Order_Item_Price,Order_Item_Price_Total,&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;What I need to do is to show the last or previous info for each Order, in any date selected.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;The Item can be twice a day or each day.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Means :&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;The last Order_Item_Quantity,Order_Item_Price,Order_Item_Price_Total&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;I know that I need to crate a history table connected to the Orders t dayable.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Please advice.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Jacov&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 17 May 2009 14:52:21 GMT</pubDate>
    <dc:creator />
    <dc:date>2009-05-17T14:52:21Z</dc:date>
    <item>
      <title>Creating History table</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144318#M23280</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Problem : Show Orders History&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;I have Orders table with Fields of Order_Item_Num,Order_Num,Order_Date,Order_Item_Quantity,Order_Item_Price,Order_Item_Price_Total,&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;What I need to do is to show the last or previous info for each Order, in any date selected.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;The Item can be twice a day or each day.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Means :&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;The last Order_Item_Quantity,Order_Item_Price,Order_Item_Price_Total&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;I know that I need to crate a history table connected to the Orders t dayable.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Please advice.&lt;/P&gt;&lt;P style="text-align: left; margin: 0cm 0cm 0pt; unicode-bidi: embed; direction: ltr;"&gt;Jacov&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 17 May 2009 14:52:21 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144318#M23280</guid>
      <dc:creator />
      <dc:date>2009-05-17T14:52:21Z</dc:date>
    </item>
    <item>
      <title>Creating History table</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144319#M23281</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hello,&lt;/P&gt;&lt;P&gt;some hints for you :&lt;/P&gt;&lt;P&gt;to get previous order line :&lt;/P&gt;&lt;P&gt;&lt;B&gt;left join (OrdersHistory) load&lt;/B&gt;&lt;/P&gt;&lt;P style="font-weight: bold"&gt;Order_Num,&lt;/P&gt;&lt;P style="font-weight: bold"&gt;Order_Item_Num,&lt;BR /&gt;&lt;/P&gt;&lt;P style="font-weight: bold"&gt;if(Order_Num = previous(Order_Num), previous(Order_Item), null()) as Previous_Item&lt;/P&gt;&lt;P style="font-weight: bold"&gt;resident OrdersHistory&lt;/P&gt;&lt;P style="font-weight: bold"&gt;order by Order_Num, Order_Item_Num;&lt;/P&gt;&lt;P&gt;to get last order line :&lt;/P&gt;&lt;P&gt;&lt;B&gt;left join (OrdersHistory)&lt;/B&gt; &lt;B&gt;load&lt;/B&gt;&lt;/P&gt;&lt;P style="font-weight: bold"&gt;Order_Num,&lt;/P&gt;&lt;P style="font-weight: bold"&gt;LastValue(Order_Item_Num) as Last_Item&lt;/P&gt;&lt;P style="font-weight: bold"&gt;resident OrdersHistory&lt;/P&gt;&lt;P style="font-weight: bold"&gt;Order by Order_Num, Order_Item_Num&lt;BR /&gt;&lt;/P&gt;&lt;P style="font-weight: bold"&gt;Group By Order_Num;&lt;/P&gt;&lt;P&gt;Hope it helps.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 17 May 2009 16:15:19 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144319#M23281</guid>
      <dc:creator>yblake</dc:creator>
      <dc:date>2009-05-17T16:15:19Z</dc:date>
    </item>
    <item>
      <title>Creating History table</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144320#M23282</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Yves,&lt;/P&gt;&lt;P&gt;It doesn't help me.&lt;/P&gt;&lt;P&gt;I need to get the info of the previous order, of the same item.&lt;/P&gt;&lt;P&gt;Since &lt;STRONG&gt;Order_Num = previous(Order_Num)&lt;/STRONG&gt; will always be NO, it will always get NULL.&lt;/P&gt;&lt;P&gt;Jacov&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 17 May 2009 17:38:51 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144320#M23282</guid>
      <dc:creator />
      <dc:date>2009-05-17T17:38:51Z</dc:date>
    </item>
    <item>
      <title>Creating History table</title>
      <link>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144321#M23283</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Jacov,&lt;/P&gt;&lt;P&gt;try function FirstSortedValue - looks like your problem could be solved with it.&lt;/P&gt;&lt;P&gt;Oleg&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Mon, 18 May 2009 00:03:38 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Creating-History-table/m-p/144321#M23283</guid>
      <dc:creator>Oleg_Troyansky</dc:creator>
      <dc:date>2009-05-18T00:03:38Z</dc:date>
    </item>
  </channel>
</rss>

