Increment fixed value in select clause
You can use user-defined variables for this.

In your first example this would be as simple as this:

SELECT
name, @rn := @rn + 1 AS ordinal
FROM
your_table
CROSS JOIN (SELECT @rn := -1) AS var_init_subquery
ORDER BY whatever_column;


Here we initialize the variable in another query. This is often more comfortable than doing this:

SET @rn := -1;
SELECT
name, @rn := @rn + 1 AS ordinal
FROM
your_table
ORDER BY whatever_column;


when you're not allowed to execute multiple statements in PHP or whatever.
The variables are session bound!
Further we initialize it here with -1 so that the first row will have value 0, because @rn + 1 is evaluated first.
Also note, that I added an ORDER BY clause. If you don't add it, your result is kind of meaningless, cause there's no order in a relational database unless you specify it. And the calculations done with any variables in the SELECT clause rely on the order of the rows.

Regarding your second example, here's just important, to take care of the order in the SELECT clause.

SELECT
name, @rn := @rn + 1 AS ordinal,
IF(@rn &lt; 2, 'first', IF(@rn &lt; 7, 'second', 'third')) AS prize
FROM
your_table
CROSS JOIN (SELECT @rn := -1) AS var_init_subquery
ORDER BY points DESC; /*or whatever_column*/