move query order