It is necessary to make a complex selection from the table with sorting for different conditions. When I make two requests separately, then everything works, and if I combine, it outputs without sorting - by the growth of the key field of the table
(SELECT *
FROM `user`
WHERE `user`.`rank_golos` >=22.1
order by `user`.rank_yearnub DESC, `user`.rank_golos DESC)
UNION ALL
(SELECT *
FROM `user`
WHERE `user`.`rank_golos` <22.1 and `user`.`rank_golos` >0
order by `user`.rank_golos DESC, `user`.rank_yearnub DESC)