I’m looking to list each table in my database and the corresponding column headers with it. Is there a way for SQL to do this and alphabetize the column names in the process?
Something along the formatting lines of:
Table1 Col1name Col2name Col3name ...
Table2 Col1name Col2name Col3name ...
...
Thanks!
And here is why I wouldn’t use
INFORMATION_SCHEMAfor anything in SQL Server 2005+: