我有这个:
ColumnA ColumnB ColumnC
Dog Soda Book
CatIce Juice Notebook
Bird Water Pencil
Dog Water Notebook
使用此选择:
select ColumnA, ColumnB, ColumnC from table
我想要一个这样的清单:
ColumnD
Bird
Book
Cat
Dog
Ice
Juice
Notebook
Pencil
Soda
Water
我该怎么做?谢谢!
答案 0 :(得分:2)
使用UNION
SELECT ColumnA
FROM table
UNION
SELECT ColumnB
FROM table
UNION
SELECT columnC
FROM table