<?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: Use LastWorkDate in Set Analysis in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729235#M1075673</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your reply. I've tried to put together an example with dummy data. Hope it makes sense. I've also creaed the variable in there&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Tue, 22 Jul 2014 21:10:26 GMT</pubDate>
    <dc:creator>Anonymous</dc:creator>
    <dc:date>2014-07-22T21:10:26Z</dc:date>
    <item>
      <title>Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729232#M1075670</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've going over this one over and over again, but now I give up and ask for your help &lt;span class="lia-unicode-emoji" title=":slightly_smiling_face:"&gt;🙂&lt;/span&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Using set analysis I have an expression in a chart, which gives me the result of yesterday (created that using inline load in my script and works great). Only problem is on Mondays, where I don't want to look at Sunday's sales, but instead Friday's sale.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I've been trying to alter this in the inline load without luck, in the set analysis, whihc obviously didn't work and finally trying to create a variable by defining last work date, but for some reason that didn't work either. Here's my last try on creating a variable and using that in my set analysis&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;sum({&amp;lt;[Appointment - Created Date]={'$(vLastWorkDay)'}&amp;gt;} [Appointment - Count])&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Definition of variable: &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;&lt;IMG __jive_id="62897" alt="Capture.PNG.png" class="jive-image" src="https://community.qlik.com/legacyfs/online/62897_Capture.PNG.png" style="width: 620px; height: 395px;" /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Any suggestions on how to solve this one? I'm certain it's simple and can be done in several ways...&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Thank you&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;Claus&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 20:43:10 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729232#M1075670</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-07-22T20:43:10Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729233#M1075671</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A quick add-on: Using the simple expression: &lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;LastWorkDate&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;(&lt;/SPAN&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt;Today&lt;/SPAN&gt;&lt;SPAN style="font-size: 8pt;"&gt;()-1,1) &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt;I get yesterdays workday, but can't use that expression in my set analysis and neither does it work as a variable&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 20:49:22 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729233#M1075671</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-07-22T20:49:22Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729234#M1075672</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;can you provide some sample data ?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 20:49:25 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729234#M1075672</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-07-22T20:49:25Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729235#M1075673</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your reply. I've tried to put together an example with dummy data. Hope it makes sense. I've also creaed the variable in there&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 21:10:26 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729235#M1075673</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-07-22T21:10:26Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729236#M1075674</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Use below expression in your Variable Definition&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=IF(WeekDay(Max([Appointment - Created Date]))=0,Date(Max([Appointment - Created Date])-3),Date(Max([Appointment - Created Date])-1))&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Now you can use your expression to get the SUM of AppointmentCount&lt;/P&gt;&lt;P&gt;=SUM({&amp;lt;[Appointment - Created Date] = {"$(=vLastWorkDay)"}&amp;gt;}[Appointment - Count])&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 21:18:59 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729236#M1075674</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-07-22T21:18:59Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729237#M1075675</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;You just need to change your Variable Expression as below&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;=IF(WeekDay(Max(Date))=0,Date(Max(Date)-3),Date(Max(Date)-1))&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 22 Jul 2014 21:23:14 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729237#M1075675</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-07-22T21:23:14Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729238#M1075676</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thank you for your help - Solution worked rigth away.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I had hoped to use the solution when looking ahead as well (same problem as when it's Friday and looking at tomorrow Saturday, where I actually want to see Monday). I have appointments (sales meetings) booked in the future and there I can't use the "max logic" on the date as they go far ahead.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Is there a way to link my Date field = Today()+1? I can't get my head around that one.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Wed, 23 Jul 2014 14:58:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729238#M1075676</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-07-23T14:58:33Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729239#M1075677</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.727272033691406px;"&gt;=IF(WeekDay(Max(Date))=4,Date(Max(Date)+3),Date(Max(Date)+1))&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2014 07:57:47 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729239#M1075677</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-07-24T07:57:47Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729240#M1075678</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi Manish,&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;But as I can have dates in the future I don't assumen the Max function will work, when I want to look at tomorrow's data?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2014 08:36:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729240#M1075678</guid>
      <dc:creator>Anonymous</dc:creator>
      <dc:date>2014-07-24T08:36:07Z</dc:date>
    </item>
    <item>
      <title>Re: Use LastWorkDate in Set Analysis</title>
      <link>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729241#M1075679</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.727272033691406px;"&gt;=IF(WeekDay(Date)=4,Date(Date+3),Date(Date+1))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif; font-size: 12.727272033691406px;"&gt;or&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 12.727272033691406px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;=IF(WeekDay(Max(Date))=4,Date(Max(Date)+3),Date(Max(Date)+1))&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 12.727272033691406px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #3d3d3d; font-size: 12.727272033691406px; font-family: 'Helvetica Neue', Helvetica, Arial, 'Lucida Grande', sans-serif;"&gt;This will work if the selected date is not the MaxDate of your database, as you don't have data for the same...&lt;BR /&gt;&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 24 Jul 2014 08:39:11 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Use-LastWorkDate-in-Set-Analysis/m-p/729241#M1075679</guid>
      <dc:creator>MK_QSL</dc:creator>
      <dc:date>2014-07-24T08:39:11Z</dc:date>
    </item>
  </channel>
</rss>

