Push select query results to an array and count for each unique value

:-X
How to push the results of a select query to an array then count for each unique value in an array. Please explain with a simple program.

And your attempt is what?

Please explain with a simple program.
Translation
I don't know how to do this. So, write it for me demonstrating how it's done.
Sponsor our Newsletter | Privacy Policy | Terms of Service