Xpress front-end record --------- MySQL

mySQL database

Database: As the name suggests, is to store the data warehouse.
 
MySQL is a relational database management systems, relational database to store data in separate tables rather than putting all the data in a large warehouse, thus increasing the speed and improved flexibility.
MySQL is a lightweight database, and PHP with the use of the effect is very good, MySQL supports most of the SQL statement.
 
Common database: oracle, mysql, sql server, MongoDB, etc.
 
 
Database operations related sql statement
show databases; # to see how many mysql database
create database database name of the charset utf8; # create database
drop database database name; # delete the database
use database name; # select which database operations
 
 
 
 
 
 
 

 

the mysql_fetch_array ();
function to obtain a result set from a line array or array of numbers as a key, or both, return line from the array generated from the acquired result set, if there are no more rows returns false.

mysql_select_db ()
MySQL database function sets the activity. If successful, the function returns true. If it fails, false is returned.
mysql_select_db (database, connection)
Parameter Description Required database. To select the specified database. connection optional. Provisions MySQL connection. If not specified, is used on a connection.

If you want to get all the data in the data set, we have to traverse the entire result set through the cycle.
Array Data = $ ();
the while ($ Row = the mysql_fetch_array ($ Result)) {
$ Data [] = $ Row;
}

 

Key: additions and deletions to change search the database (curd)

 

 

 

 

 

Guess you like

Origin www.cnblogs.com/hudunyu/p/11427408.html