fix order by by deviceid