T-SQL 101: #11 The Basic Syntax of a T-SQL SELECT Statement

The most basic form of SELECT statement that we used to get information out of a table is the word SELECT followed by a list of columns or expressions that we want, and then details of where we need to get them from. Typically, that's a table.

The basic syntax of a SELECT statement in SQL Server T-SQL is as follows:

Committees are curious things, and I can't say that I always agree with their outcomes. I suspect if I'd been designing this, I would have had:

FROM <where>
SELECT <what to select>

as that's the logical order that it happens in.

As well as a single table, the FROM clause could involve a number of different tables joined together. We will see that later in this series when we start working with multiple tables.

Learning T-SQL


Leave a Reply
