Choosing Specific Columns

To select specific columns in a table, explicitly list each column in the select list. For example, to list only the employee first names and their telephone numbers, use:

SELECT c.FirstName, c.Phone
FROM AdventureWorks.HumanResources.Employee e
JOIN AdventureWorks.Person.Contact c
ON e.ContactID = c.ContactID
ORDER BY FirstName ASC

Specifying the columns in the select list can also include specifying an alias (for example, proj_sales AS "Projected Sales") or other expressions, such as (price = price * 1.15, or SUM(SalesAmount).

See Also

Other Resources

SELECT (Transact-SQL)

Help and Information

Getting SQL Server 2005 Assistance