rename a column in sql server with alter table code example
Example 1: sql rename column
EXEC SP_RENAME 'TABLE_NAME.OLD_COLUMN_NAME','NEW_COLUMN_NAME'
Example 2: sql rename column in select query
SELECT data.column AS `Label`
EXEC SP_RENAME 'TABLE_NAME.OLD_COLUMN_NAME','NEW_COLUMN_NAME'
SELECT data.column AS `Label`