How do I get column name from a SQL statement? Is there any easy way just to get the column names returned from a SQL statement ?

Such as: 

 SELECT * 
 FROM ATable 
 FULL OUTER JOIN BTable b ON a.SOME_KEY = b.SOME_KEY
 FULL OUTER JOIN CTable c ON b.SOME_ID = c.SOME_ID
 FULL OUTER JOIN DTable d ON a.SOME_OTHER_ID = d.SOME_OTHER_ID
 WHERE a.SOME_KEY = @key AND c.SOME_SERIAL_NR = @serialnumber


I cannot seem to get 

select column_name 
from information_schema.columns 
where table_name = 'table' 


to work in my current context
I prefer this query, for a number of reasons:

SELECT 
  [table]  = s.name + N'.' + t.name, 
  [column] = c.name
FROM sys.columns AS c
INNER JOIN sys.tables AS t
  ON c.[object_id] = t.[object_id]
INNER JOIN sys.schemas AS s
  ON t.[schema_id] = s.[schema_id]
WHERE t.name IN (N'ATable', N'BTable', N'CTable', N'DTable');



You can tell which column comes from which table
You can see the schema (schema is important)
You avoid the broken and incomplete INFORMATION_SCHEMA views - this doesn't cause a problem for this particular query, but there will be cases where you can't rely on metadata from INFORMATION_SCHEMA
You should be in the habit of always using the N prefix on string literals when the underlying data type in nchar/nvarchar.
You should also get into the habit of using proper statement terminators


The cons with my solution:


It takes a few seconds longer to type
It won't run on Oracle, MySQL, Postgres, etc.