Hi,
I have a table of items. item has id, score 1, score 2
I want to select 12 known items (using WHERE id IN (....)) and order them by a score that is the sum of score1 and score2's ranks. rank is the location of the score if the 12 items were ordered by it.
How can I do this in mysql?
Edit:
After 4 answers I see that the solution is probably more complicated than I expected. so let me ask the question in another way.
if I use select *, [calculation] from table where id IN (odered list of ids). Can I somehow use the position of each id in the original ordered list of ids in [calculation]?