Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
the following is my data model attached. I want to display the number of hires and terminations each year. Any Ideas?
create two year fields based on Employment Date and Termination Date and then use count( distinct EMPNO) as expression with the newly created years as dimension (2 different charts)
You can take inspiration from the demo file "Human Resources.qvw" from Qlik website.
If you want to show both the counts on the same chart (i.e. bar chart), create a date island table (year,qtr etc) then
use the year field from this table and add 2 expressions like this,
count( DISTINCT if(year=hire_year,emp_cnt)
count( DISTINCT if(year=year_terminated,emp_cnt)
you could use a canonical calendar
How should I create the two year fields?
creating a master calendar should be a good way to start
Can I do it without creating the master table? How can i extract just the year from the employment date and compare it with the payroll year?