Select rows in random order and then reverse it
- by Faruz
I need to select rows in random order and return a query which holds the rows in both regular order and in reverse order. This is done to simulate a fantasy draft for a basketball game I'm working on.
For example, I need a result set as followed:
team1 1
team2 2
team6 3
team9 4
team9 5
team6 6
team2 7
team1 8
As you can see, the first four teams are random then then following four are in reverse order.
Hope I managed to explain the problem, if not - please comment and I'll explain further.