Is it possible to make a union from two tables with开发者_Go百科 different number of columns, values and column types in Sybase SQL?
Sure, as long as the columns from the top and bottom part of the union can be converted to the same type. For example:
select intColumn as col1
, charColumn as col2
, decimalColumn as col3
from Table1
union all
select null
, 'Halelujah'
, doubleColumn
from Table2
精彩评论