Unlock a world of possibilities! Login now and discover the exclusive benefits awaiting you.
Hi,
I've got this issue with my histogram : I have to choose between several years (the dimension), and if only 1 year is picked, I have one column, in the other case, I have as much columns as years picked.
The principe is the next : count(NUM_JOUR)/((count( {$<NUM_ANNEE = >} AGENT_ID )/12)*365). In this expression, the Count(NUM_JOUR) doesn't work when there are 2+ years picked.
As we can see, there is num_annee which influence the histogram, but when you pick 1 or several years, it's also change a variable called : annee_conge. count(NUM_JOUR) depends of annee_conge and ((count( {$<NUM_ANNEE = >} AGENT_ID )/12)*365) depends of num_annee.
Right now, it's NUM_JOUR_2009 + NUM_JOUR_2010, which are divided by the rest of the expression. But I want the first bar to be divided by NUM_JOUR_2009 and the second one by NUM_JOUR_2010.
How to make to specify to Count(NUM_JOUR) to pick for every column only the year concerned and not the sum of every year ?
Which is the relation between num_annee and NUM_JOUR in your data model? Aren't they in the same table? If you could post your data model information it would be helpful.
the thing is the data model is not optimized, and for the comprehension, I changed a name. annee_conge = NUM_ANNEE
So there is a num_annee and a NUM_ANNEE, and I'm affraid that is the problem, so this is why I want to specify.
Yes, the problem seems to be there. The num_annee you have in the agent table is not the same that you have in the calendar, so QV cannot make a proper relation between them. You should have all the date fields in the same table (both, num_annee and NUM_JOUR)
NUM_JOUR is in Calendrier, I wasn't paying attention, and I forgot to maximize the window.
The thing is , in Calendrier, the year is the year where an employee was absent, and in agent, it's the year where he was employed. So I need this distinction between those two. But right now I changed the name of NUM_ANNEE to annee_conge, but still, I've got the same issue.
The two aren't linked anymore, but when I want to pick two dates, it's a sum of NUM_JOUR of the dates.
I rehost the good data model