select 1+t1.n as number, t2.num
from
(select 0 n union select 1 union select 2 union select 3 union select 4
union select 5 union select 6 union select 7 union select 8 union select 9 ) t1
left join rate t2 on t1.n=t2.num and t2.usersid=1
order by number
если = null тогда
...
иначе
....