Networking, Programming and Graphics Tutorials

MySQL SELECT query from PHP script [1/2]

Type: Code Networking, Programming and Graphics Tutorials
MySQL SELECT query from PHP script
Level: Beginner Networking, Programming and Graphics Tutorials 
MySQL SELECT query from PHP script
Date: 2007-Mar-16
MySQL SELECT query from PHP script
Visited: 9867 times
MySQL SELECT query from PHP script
Rating: MySQL SELECT query from PHP script
MySQL SELECT query from PHP script
Author: Ivory Morhuld

This tutorial will show you how to use MySQL querys to database in your PHP scripts.

mysql_query(query, [link_identifier])


mysql_query() sends a query to the currently active database on the server that's associated with the specified link identifier. If link_identifier isn't specified, the last opened link is assumed. If no link is open, the function tries to establish a link as if mysql_connect() was called with no arguments, and use it.

In next examples we will teach you how to make more querys.

<?php
$quety
="select * from table";
$result=mysql_query($query);
?> 
Above example will return you:

ID Name Sex Age
1 John Smith Male 33
2 Barbara Roland Female 28
3 Kate Winston Female 22
4 Peter Trump Male 46
5 Andrea Gilbert Female 37
Networking, Programming and Graphics Tutorials - MySQL SELECT query from PHP script [1/2] - Networking, Programming and Graphics Tutorials

Need a specific tutorial? Do not hesitate and submit a request!
Related Tags: mysql query from script select  php script mysql select query  php script+mysql+select query  example script of mysql query select in php  select query in mysql from a script  php script mysql query select from table  php select query script  select query script of php  select query script  php script select query  SELECT query from PHP script [1/2]  script query select  select query in php script  select query +php+script  php script for select query  code for select query in php script  php script creating a select query  statement select query script  select query with html script  select query PHP sample script