SELECT statement which is used to retrieve data from a table in the database.
Retrieval of data can be from specific columns or from all the columns in the table.
To create a simple SQL SELECT Statement, you must specify the column(s) name and the table name. The whole query is called SQL SELECT Statement.
By using select we can retrieve either few columns or all columns.
Syntax:
Select col1, col2, coln
From
· Table-name is the name of the table from which the information is retrieved.
· Col1, col2, coln means one or more columns from which data is retrieved.
· in where clause are defined to restrict the data when fetching from table.
selecting few Columns:-
Displaying ALL COLUMNS:-
No comments:
Post a Comment