我想在SELECT子句中使用别名列作为另一个列。
select col_1/col_2+col_3 as new_col,
new_col+10 as new_col_2
from table
我想在SELECT子句中使用别名列作为另一个列。
select col_1/col_2+col_3 as new_col,
new_col+10 as new_col_2
from table
select new_col, new_col + 10 as new_col_2
from (
select col_1 / col_2 + col_3 as new_col
from table
) t