Anda dapat menggunakan insert into table[b](query,date) select query,date from table[a] order by table[a] asc