Difference between revisions of "Category:SQL"

From database24
Jump to navigation Jump to search
(Created page with '== Basics == === Select === * SELECT === Insert === * INSERT INTO === Update === * UPDATE === Delete === * DELETE == Formatting == * [[Well Formed SQL Statements|Well Formed...')
 
Line 2: Line 2:
  
 
=== Select ===
 
=== Select ===
* SELECT
+
The SELECT statement is used to assemble fields of different tables and queries to a new result.
 +
 
 +
==== Examples ====
 +
* Selecting all fields from a table
 +
<syntaxhighlight lang=SQL>
 +
SELECT *
 +
  FROM tbl
 +
</syntaxhighlight>
 +
 
 +
* Selecting two fields from a table
 +
<syntaxhighlight lang=SQL>
 +
SELECT field1
 +
    , field2
 +
  FROM tbl
 +
</syntaxhighlight>
 +
 
  
 
=== Insert ===
 
=== Insert ===
Line 12: Line 27:
 
=== Delete ===
 
=== Delete ===
 
* DELETE
 
* DELETE
 +
 +
 +
== Joins ==
 +
 +
 +
== Distinct ==
 +
 +
 +
== Sub Select ==
  
 
== Formatting ==
 
== Formatting ==

Revision as of 13:32, 22 July 2010

Basics

Select

The SELECT statement is used to assemble fields of different tables and queries to a new result.

Examples

  • Selecting all fields from a table
SELECT *
  FROM tbl
  • Selecting two fields from a table
SELECT field1
     , field2
  FROM tbl


Insert

  • INSERT INTO

Update

  • UPDATE

Delete

  • DELETE


Joins

Distinct

Sub Select

Formatting

Special SQL

  • Microsoft Access OLEDB

Tools

Pages in category "SQL"

The following 5 pages are in this category, out of 5 total.