Select query in mysql

Select command is used to fetch the rows from one or more tables. The most comman and useful command is as :

Select * from table_name


Above command retrieve all rows and columns of a table.The star sign (*) is used to select all columns from table. We may  retrieve data from specific columns by using names of columns in select command separated by commas.

select col_name1,col_name2 from  table_name
.

We can also use select command to get computed row without any table reference.

select 2+1 
 

The result is 3