Select Data from MySQL | Learn MySQL Online

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;

Best WordPress Hosting


Discount Coupons

Get a .COM for just $6.98

Secure Domain for a Mini Price

Leave a Reply

    Waiting for your comments