SQL Server Performance, DBA Best Practices & Enterprise Data Solutions | MyTechMantra
Home » SQL Server Tutorial » SQL SELECT | SQL QUERY | SQL SELECT Statement T-SQL Tutorial with Examples

SQL SELECT | SQL QUERY | SQL SELECT Statement T-SQL Tutorial with Examples

SQL SERVER SELECT Statement | SQL SELECT TABLE | SQL SELECT | SQL QUERY

The “SQL SELECT statement” is used to select data from a database.

In SQL SERVER, the SELECT Statement is used to query the data stored in a given table of a database. The data which is returned by executing the SELECT statement is referred as result-set.

Within a database data is stored within tables. In a table the data is stored in rows and columns.

In this tutorial, you will learn about Transact-SQL (T-SQL) along with relevant examples. To understand each topic in detail we recommend you to follow the sequence of articles.

This is Part 1 of 40 Part SQL Server T-SQL Tutorial.

Topics Covered in SQL Server T-SQL Tutorial are:

SELECT Syntax / SQL Server SELECT Statement Syntax

Use <DatabaseName>
GO

SELECT column1, column2, column3,.......
FROM schema.table
GO


SQL SELECT Statement | SQL Server SELECT Statement | How to Query Data from a Table in SQL Server

How to SELECT all columns from a table

To select all the columns and data from a table execute the below SELECT Statement in SQL Server Management Studio (SSMS).

Use the below script to fetch the data from AdventureWorks2016 sample database in SQL Server 2016. For more information on How to Download SQL Server 2016 and Sample Database, refer How to Download SQL Server 2016 Developer Edition for Free.

Use AdventureWorks2016
GO

SELECT * FROM HumanResources.Employee
GO
SQL SELECT Statement | SQL Server Select Statement How to Query a Table to Fetch Results


How to SELECT required columns from a table

To select some of the columns and data from a table execute the below SELECT Statement in SSMS.

Use AdventureWorks2016
GO

SELECT 
	  FirstName
	, LastName 
FROM Person.Person
GO
SQL SELECT Statement Tutorial | SQL Server Select Statement Results

We recommend you to go thought all the topics of SQL Server Transact-SQL Tutorial in the sequence for better understanding of Transact-SQL. Click Next Page button to continue reading the topics and click on the Previous Page button to revisit the previous topic.

Next Page..





SQL SERVER SELECT Statement | SQL SELECT TABLE | SQL SELECT | SQL QUERY

Ashish Kumar Mehta

Ashish Kumar Mehta is a distinguished Database Architect, Manager, and Technical Author with over two decades of hands-on IT experience. A recognized expert in the SQL Server ecosystem, Ashish’s expertise spans the entire evolution of the platform—from SQL Server 2000 to the cutting-edge SQL Server 2025.

Throughout his career, Ashish has authored 500+ technical articles across leading technology portals, establishing himself as a global voice in Database Administration (DBA), performance tuning, and cloud-native database modernization. His deep technical mastery extends beyond on-premises environments into the cloud, with a specialized focus on Google Cloud (GCP), AWS, and PostgreSQL.

As a consultant and project lead, he has architected and delivered high-stakes database infrastructure, data warehousing, and global migration projects for industry giants, including Microsoft, Hewlett-Packard (HP), Cognizant, and Centrica PLC (UK) / British Gas.

Ashish holds a degree in Computer Science Engineering and maintains an elite tier of industry certifications, including MCITP (Database Administrator), MCDBA (SQL Server 2000), and MCTS. His unique "Mantra" approach to technical training and documentation continues to help thousands of DBAs worldwide navigate the complexities of modern database management.

Follow us

Don't be shy, get in touch. We love meeting interesting people and making new friends.