My result table contains fields:
id count
____________
1 3
2 2
3 2
From this table I need to form another table score , which should look like this
id my_score
_____________
1 1.0000
2 0.6667
3 0.6667
This my_score=count/MAX(count), but if I give a request like
create TEMPORARY TABLE(select id,(count/MAX(count)) AS my_score from result);
only the 1st row is retrieved.
Can anyone suggest a request so that my_score is computed for all tuples.
Thanks in advance.
source
share