Current course:

MySQL select statement


Description:

An "select" statement is used to retrieve information from one or more rows in a table.

The Code:

SELECT field1, field3, field6 FROM table
SELECT first, last, email FROM people WHERE last='schwan' LIMIT 1

Or, in php:
mysql_query("SELECT field1, field3, field6 FROM table");
mysql_query("SELECT first, last, email FROM people WHERE last='schwan' LIMIT 1");