Skip to main content
Announcements
Qlik Connect 2024! Seize endless possibilities! LEARN MORE
cancel
Showing results for 
Search instead for 
Did you mean: 
Not applicable

% by column and row to a PivotTable

Hello, I have the same problem but with a formula SET ANALYSIS, I tried the formula proposed by OKG but it does not give me the right result. I have a PivotTable with two dimensions: source of employment year

Count (DISTINCT {$ <contract = {'CDI'} between {= '1'}>} [id_salarie]): nbr of CDI hirings

I want to have for each year, the% of each source hiring

The formula I tried

Count (DISTINCT {$ <contract = {'CDI'} between = {'1'}>} [id_salarie]) / count (DISTINCT total <year> {$ <contract = {'CDI'} between = {'1 '}>} [id_salarie])

The formula gives me the% from the total of all years

Help please !

(posted edited by OKG; translation done by Google Translate)

6 Replies
marcus_sommer

Try something like this:

Count ({$ <contract = {'CDI'}, between = {'1'}>} DISTINCT [id_salarie]) /

Count ({$ <contract = {'CDI'}, between = {'1'}>} DISTINCT total <year> [id_salarie])

- Marcus

Not applicable
Author

Thank you Marcus but it gives the same result that i have with my formula !

marcus_sommer

Normally this approach worked to get the quotes. Maybe there are other things to be considered - is more than one year available - this might be restricted by other selections or are there alternate states and is this year-field a dimension within the chart?

- Marcus

Not applicable
Author

Marcus, the year field is a dimension of the table and I verified that i have no selection. Below is  my pivot table:% Pivot table.png

marcus_sommer

You need your other dimension Source also within the total statement: total <year, Source>


- Marcus

satheshreddy
Creator III
Creator III

Hi Amoira,

Are You tried in Number Tab we can select Particular Exp and select Integer And Check the  show in percentage, may it will comes % entire Hiring Column.

Regards

Sathish