select x1, x2, x3 from
(select x1, x2, x3 from table1
union all
select x1, x2, x3 from table2) as test;
前:
select order_id,order_date from orders limit 1
union all
select order_id,order_date from orders limit 1;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
_u1.order_id _u1.order_date
1 2013-07-25 00:00:00.0
1 2013-07-25 00:00:00.0
後:
select order_id, order_date from
(select order_id,order_date from orders limit 1
union all
select order_id,order_date from orders limit 1) as test;
~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
order_id order_date
1 2013-07-25 00:00:00.0
1 2013-07-25 00:00:00.0
比ks,但可以直接重新定義列名稱嗎?沒有添加一行新的選擇.... – lserlohn
不,沒有任何這樣的選項,據我所知。 –