Qlik Community

New to QlikView

Discussion board where members can get started with QlikView.

Announcements

Breathe easy -- you now have more time to plan your next steps with Qlik!
QlikView 11.2 Extended Support is now valid through December 31, 2020. Click here for more information.

Not applicable

filter listbox of year to display all record of the current year and previous

Hi everyone,

I have a listbox that capture the years of hired date and displays it in horizontal view. So If you click on a year it will display all employee hired on that current year.  But I want it to display all the employees of the current hire and the previous the years.  Example is attached

Here's my code

Load

HireDate,

Year(HireDate) as Year

Month(HireDat) as Month

From

myexcel.xlsx


From here I created two list box , one for Year and the other for Month.

Thanks

2 Replies
Not applicable

Re: filter listbox of year to display all record of the current year and previous

Hi,

I try to make a sample for your query..

What i understand from your question is that, when you select a year from the list box, you want to show the emp which are on that selected year and previous year of that selection.

for that purpose, i create two variables which are holding max(Year) and max(Year)-1. And by using the straight table, i write a set analysis to get the selected year and the previous year's list of employes.

I attach the document.

I hope, it will help you.

BR

Omer

Not applicable

filter listbox of year to display all record of the current year and previous

Hi Omer,

Sorry I took so long to reply,  your suggestion worked great. But is there a way to put the count forumal in the year list box?  Currently you have it on the employee/year straight table.

Reason being is that I got pleny of strainght tables and want to avoid duplicate forumal entry