我可以从查询结果中别名列名吗?为什么这个查询不起作用?
select
column_code AS (select column_name from column_registers where column_registers_id = column_code)
from other_table;
我的目标是查询结果的“列名”。 感谢。
答案 0 :(得分:0)
应该是这样的
select
(select column_name from column_registers where column_registers_id = column_code) AS column_code
from other_table;