|
LastName |
FirstName |
Address |
City |
ABC |
EFG |
1, |
|
XYZ |
EFG |
3, |
|
EFG |
ABC |
2, |
|
FirstName |
Address |
City |
EFG |
1, |
|
EFG |
3, |
|
ABC |
2, |
|
LastName |
FirstName |
Address |
City |
ABC |
EFG |
1, |
|
SELECT Statement Example |
Consider the table Student: Student |
SELECT FirstName, Address, City FROM Student This query displays all the records with the columns FirstName, Address and City. |
The query given below will select only those records which have the value for the city field as chicago. SELECT * FROM Student WHERE City=Chicago The * in the SELECT statement denotes that all columns from the table will be chosen. |