Last active
March 21, 2025 19:07
-
-
Save tcartwright/20a9ce408e83ccfaca0d31248302524b to your computer and use it in GitHub Desktop.
SQL SERVER: The various ways to alias a column
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
-- Examples of the various ways to alias columns. All other methods except for #1 are deprectated or older styles | |
SELECT | |
1 AS [one], | |
2 [two], | |
3 AS 'three', | |
4 'four', | |
5 AS "five", | |
6 "six", | |
[seven] = 7, | |
'eight' = 8, | |
"nine" = 9 | |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment