<?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: Month and Year listbox selection in QlikView</title>
    <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328244#M1183428</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Whoops, I put an extra right paren in there.&amp;nbsp; Should be this I think, and I'm correcting the previous post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD date(fieldvalue('OrderDate',recno())) as OrderDate&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Thu, 17 Nov 2011 20:28:20 GMT</pubDate>
    <dc:creator>johnw</dc:creator>
    <dc:date>2011-11-17T20:28:20Z</dc:date>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328241#M1183425</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;This seems like a basic question as this feature seems to be common.&amp;nbsp; I've seen this accross the top of most example dashboards.&amp;nbsp; &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;How can I take a sales date column and create a listbox that contains unique values of the dates in both month spelled out (Jan) format and YYYY.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Also, how do you make the listbox horizontal instead of vertical?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Thanks.&amp;nbsp;&amp;nbsp; &lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 19:55:07 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328241#M1183425</guid>
      <dc:creator />
      <dc:date>2011-11-17T19:55:07Z</dc:date>
    </item>
    <item>
      <title>Re: Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328242#M1183426</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;In script, something like this to generate a calendar table based on your sales dates.&amp;nbsp; The calendar table will add the month and year fields to your model.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;[Calendar]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,month(OrderDate) as OrderMonth&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,year(OrderDate) as OrderYear&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD date(fieldvalue('OrderDate',recno())) as OrderDate&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE fieldvaluecount('OrderDate')&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;To make the list box horizontal, in the properties, presentation tab, uncheck "single column" and then make the box short and wide.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 20:00:49 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328242#M1183426</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-11-17T20:00:49Z</dc:date>
    </item>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328243#M1183427</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks John!&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;It came back with this error.&lt;/P&gt;&lt;P&gt;--------------------------------------&lt;/P&gt;&lt;P&gt;Error in expression:&lt;BR /&gt;FieldValue takes 2 parameters&lt;/P&gt;&lt;P&gt;LOAD date(fieldvalue('OrderDate'),recno())) as "Sales Date"&lt;BR /&gt;AUTOGENERATE fieldvaluecount('OrderDate')&lt;/P&gt;&lt;P&gt;--------------------------------------&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;OrderDate has my dates in it..&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 20:10:00 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328243#M1183427</guid>
      <dc:creator />
      <dc:date>2011-11-17T20:10:00Z</dc:date>
    </item>
    <item>
      <title>Re: Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328244#M1183428</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Whoops, I put an extra right paren in there.&amp;nbsp; Should be this I think, and I'm correcting the previous post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD date(fieldvalue('OrderDate',recno())) as OrderDate&lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 20:28:20 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328244#M1183428</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2011-11-17T20:28:20Z</dc:date>
    </item>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328245#M1183429</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Thank you!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 17 Nov 2011 20:49:55 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328245#M1183429</guid>
      <dc:creator />
      <dc:date>2011-11-17T20:49:55Z</dc:date>
    </item>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328246#M1183430</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; I too have the same problem and tried to used the script provided.&amp;nbsp; I have a termination data on a page and my source file has 1/1/2010 for Example - I need to be able to select any month in a list box and then and year in a list box and I of course do not want to manipulate the source data.&amp;nbsp; Is the formula I am using correct?&amp;nbsp; Term Date is field heading.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;[Calendar]:&lt;/P&gt;&lt;P&gt;LOAD *&lt;/P&gt;&lt;P&gt;,month([Term Date]) as TermMonth&lt;/P&gt;&lt;P&gt;,year([Term Date]) as TermYear&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;LOAD date(fieldvalue(['Term Date'],recno())) as [Term Date]&lt;/P&gt;&lt;P&gt;AUTOGENERATE fieldvaluecount(['Term Date'])&lt;/P&gt;&lt;P&gt;;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="color: #0000ff; font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;SPAN style="font-size: 8pt;"&gt; &lt;/SPAN&gt;&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sat, 18 Feb 2012 01:26:58 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328246#M1183430</guid>
      <dc:creator />
      <dc:date>2012-02-18T01:26:58Z</dc:date>
    </item>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328247#M1183431</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The script given assumes you've already loaded "Term Date" from your source, and that it's a QlikView date.&amp;nbsp; I'm not clear if you've done that.&amp;nbsp; You're also not matching the syntax for the fieldvalue() and fieldvaluecount() functions, which don't use brackets.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 17:40:03 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328247#M1183431</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2012-02-21T17:40:03Z</dc:date>
    </item>
    <item>
      <title>Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328248#M1183432</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt; Yes John, Term Date is a field in my source document.&amp;nbsp; I'm not sure I understand what you mean when you say 'if it's a QlikView date'&amp;nbsp; When I read it makes me think I will have to edit my source data which I don't want to do. Am i thinking about this correctly?&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In terms of the syntax, i'm purely a QV novice - what am I doing wrong there?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 18:51:28 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328248#M1183432</guid>
      <dc:creator />
      <dc:date>2012-02-21T18:51:28Z</dc:date>
    </item>
    <item>
      <title>Re: Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328249#M1183433</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;A QlikView date means a date in QlikView's internal format, often created using the date() and/or date#() functions.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;No, don't edit the source data.&amp;nbsp; I gather that your source document is an Excel file.&amp;nbsp; I don't use many Excel files, but it looks like QlikView understands an Excel date without any further manipulation.&amp;nbsp; So your script might look something like this:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;[Data]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;ID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,[Term Date]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;FROM TermDate.xlsx (ooxml, embedded labels, table is Sheet1)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;[Calendar]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,month([Term Date]) as [Term Month]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,year([Term Date]) as [Term Year]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD date(fieldvalue('Term Date',recno())) as [Term Date]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE fieldvaluecount('Term Date')&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;I personally prefer to have my Month fields include the year, and both my Month and Year fields to be QlikView dates (so that I can manipulate them with QlikView date functions).&amp;nbsp; That would look like this instead:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;[Data]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;ID&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,[Term Date]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;FROM TermDate.xlsx (ooxml, embedded labels, table is Sheet1)&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;[Calendar]:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD *&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,date(monthstart([Term Date]),'MMM YYYY') as [Term Month]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;,date(yearstart([Term Date]),'YYYY') as [Term Year]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;LOAD date(fieldvalue('Term Date',recno())) as [Term Date]&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;AUTOGENERATE fieldvaluecount('Term Date')&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN style="font-family: courier new,courier;"&gt;;&lt;/SPAN&gt;&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;For syntax questions, or other questions about how functions are used, I'd recommend just searching for them in the help file.&amp;nbsp; That should give you syntax, how the function is used, and typically a few examples.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 19:07:33 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328249#M1183433</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2012-02-21T19:07:33Z</dc:date>
    </item>
    <item>
      <title>Re: Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328250#M1183434</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;(i have not tried it) but this is great John, You are correct, I am working from an excel file, so then when I go to create the list box - what field am I choosing to be the selection?&amp;nbsp; is it monthstart (for months)? &lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;And I agree I like to have years associated with months - Does your formula above capture that?&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 20:20:39 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328250#M1183434</guid>
      <dc:creator />
      <dc:date>2012-02-21T20:20:39Z</dc:date>
    </item>
    <item>
      <title>Re: Month and Year listbox selection</title>
      <link>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328251#M1183435</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;The field names are the part in [] after "as" in each of the loads, or just the name given in the source file if there is no "as".&amp;nbsp; You'll see them when you build a list box, so once you've run the script, it shouldn't be confusing.&amp;nbsp; They'll be these for the above example:&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;ID&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;Term Date&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;Term Month&lt;/P&gt;&lt;P style="padding-left: 30px;"&gt;Term Year&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;The second script I gave includes the years associated with the months.&amp;nbsp; The first does not.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 21 Feb 2012 20:26:41 GMT</pubDate>
      <guid>https://community.qlik.com/t5/QlikView/Month-and-Year-listbox-selection/m-p/328251#M1183435</guid>
      <dc:creator>johnw</dc:creator>
      <dc:date>2012-02-21T20:26:41Z</dc:date>
    </item>
  </channel>
</rss>

