There is a column 'client_code'
in sql table 'tb_accounts'
. I want to create a select
statement with two column aliases 'cl_code'
and 'acc_num'
, but all populated from the 'client_code'
column.
Advertisement
Answer
Select results are aliased like:
SELECT acc.client_code as acc_num, acc.client_code as cl_code FROM tb_accounts as acc WHERE ....