Select Data from MySql

Select Data from MySql

‘SELECT’ statement is used to select the data from the table. If you want to select all the data from the table, then the

Syntax :

SELECT * FROM table_name;

And, if you want to select particular FIELD from the table, then the SYNTAX will be :

SELECT name FROM student;

After selecting a particular field like ‘name’ from the table like ‘student’, only that field will be selected.

Example :


$sql="SELECT * FROM table_name";

// Now all data fetch from table, * is use for fetch all data from database

$result= mysql_query($sql);
$row= mysql_fetch_array($result);

echo $row;


Coding Tag

Coding Tag always happy to serve you in Information Technology (IT). Learn HTML, CSS, Javascript, PHP, Android, Digital Marketing, Latest IT News and many more.

Leave a Reply

Notify of