Select (SQL): Difference between revisions

Content deleted Content added
use new article name for Db2
m linking
Line 6:
The SELECT statement has many optional clauses:
 
* <code>SELECT</code> clause is the list of [[column (database)|columns]] or SQL expressions that must be returned by the query. This is approximately the [[relational algebra]] [[Projection_(relational_algebra)|projection]] operation.
* <code>[[Alias (SQL)|AS]]</code> optionally provides an alias for each column or expression in the <code>SELECT</code> clause. This is the relational algebra [[Rename_(relational_algebra)|rename]] operation.
* <code>[[From (SQL)|FROM]]</code> specifies from which table to get the data.<ref>Omitting FROM clause isn't standard, but allowed by most major DBMSes.</ref>