R
RaveendiraN RR
Hi,
I have a user database as shown
User Score
u1 1
u2 2
u1 4
u3 7
u2 1
u1 6
u2 5
u1 2
I want a query that would give me the result where i would get the
percentage break up scores by the each user for a particluar score, say U1
has 25% of scores as 1 (formula= count the number of times the user obatined
the score/ total times the user name has appeared in the database)
Further more i want to group the based on scores between 1 and 4, 5 and 7,
8 and 9 gining the percentage break up by user for these groups
Example:
User Group1 Group2 Group3
U1 75% 25% 0%
How can this be achieved in one query?
If this is not possible in a single query, how can this be achieved ? Please
help !!!
Thanks,
Raveendiran RR
Mail: (e-mail address removed)
I have a user database as shown
User Score
u1 1
u2 2
u1 4
u3 7
u2 1
u1 6
u2 5
u1 2
I want a query that would give me the result where i would get the
percentage break up scores by the each user for a particluar score, say U1
has 25% of scores as 1 (formula= count the number of times the user obatined
the score/ total times the user name has appeared in the database)
Further more i want to group the based on scores between 1 and 4, 5 and 7,
8 and 9 gining the percentage break up by user for these groups
Example:
User Group1 Group2 Group3
U1 75% 25% 0%
How can this be achieved in one query?
If this is not possible in a single query, how can this be achieved ? Please
help !!!
Thanks,
Raveendiran RR
Mail: (e-mail address removed)