![](/img/trans.png)
[英]Teradata SQL Tuning Multiple columns in a huge table being joined to the same table with OR condition on the filter
[英]Teradata SQL Tuning. Aliasing a union all column in a dervied table
我確定我可能會丟失一些東西,但是有一種方法可以別名化派生表中的結果數據集列
sel tb1.C1
, Tb2.C2
, ( sel DC1.Col1
from ( DC1 logic here) DC1
UNION ALL
DC2.col2
from ( DC2 Logic here ) DC2
) D_outer
where conditions
我想為DC1.col1 UNION ALL DC2.col2的D_outer中的Column加上別名,以便我可以為其他名稱調用它,我正在嘗試做
我重新格式化了您的SQL,但它似乎不完整。 通常,列別名和數據類型由UNION中的第一個SELECT語句驅動
聲明:本站的技術帖子網頁,遵循CC BY-SA 4.0協議,如果您需要轉載,請注明本站網址或者原文地址。任何問題請咨詢:yoyou2525@163.com.