I. References
Http://dev.mysql.com/doc/refman/5.1/zh/sql-syntax.html#create-table
Http://www.cnblogs.com/yunf/archive/2011/04/20/2022193.html
Http://www.blogjava.net/coderdream/archive/2007/08/17/137642.html
Ii. Create a table
Today, when I learned yii by following the example in the book, I found that the following error is always reported when I create a MySQL table with a foreign key.
Error 1005 (hy000): Can't create table '. ' (errno: 150)
However, the error
First step (generally omitted ):Enable the MySQL Service (it runs automatically when it is started by default ):Control Panel --> Administrative Tools --> service, find the item named MySql in it, and double-click it to see whether its service
Stored Procedure and cursor Core:# Variables must be declared at the beginning Declare Nomorerows bool Default False; Declare _ Id Int ; Declare _ Name Varchar ( 25 );# Declare a cursor Declare Xxrows Cursor For Select * From XX;# Set
1. Add a userGrant all privileges on *. * To 'root' @ '%' identified by 'Password' with grant option;Flush privileges;
2. remote connectionUse MySQL;Update user set host = '%' where user = 'root ';
3.
Mysql-u root MySQL
Mysql> Update
Introduction: this is to go to PhPProgramThe 11 most common MySQL errors page describes PHP, related knowledge, skills, experience, and some PHP source code.
Class = 'pingjiaf' frameborder = '0' src = 'HTTP: // biancheng.dnbc?info/pingjia.php? Id =
During my project, I have made some adjustments and Optimizations to MySQL system configuration parameters, such as connection timeout disconnection, SQL exceeding the buffer length limit, and memory table size adjustment, here we will sort out the
FromHttp://androider.javaeye.com/blog/352332
Meanings of foreign key constraints on subtables:If no candidate key is found in the parent table, insert/update is not allowed in the child table.
meanings of foreign key constraints on parent
Turn: http://www.68design.net/Development/Database/25689-2.html
Many friends have installed MySQL but do not know how to use it. In this article, we will connect to MySQL,You can learn some common MySQL commands by changing passwords and adding
Here is an example of using the date function. The following query Selects all records. The value of date_col is within the last 30 days:
Date_format (from_unixtime ('2017-10-04 22:23:00 '),' % Y/% m/% D ')
Mysql> select something from tableWhere
From: http://www.heiqu.com/show-64764-1.html
Content:
During MySQL installation, the underlying encoding method was neglected and the default ASCII encoding format was used. As a result, the problem of Chinese conversion followed one after another.
1. Connect to the databaseFormat: mysql-u username-P Password
Ii. Change the passwordFormat: mysqladmin-u username-P old Password New PasswordIii. database usageFormat: Use Database Name
4. display tables in the databaseFormat: Use Database
MyISAM and InnoDB
InnoDB and MyISAM are the two most common table types used by many people when using MySQL. The two table types have their own advantages and disadvantages, depending on the specific application. The basic difference is that the
Install Apache
If you select to listen to port 8080 during installation, start it manually. After the installation is complete, go to the bin directory of the installation directory and runApache-K installAdd Apache to the service list of windows.
How to Implement the isnull function in mssql in mysql
========================================================== ============
IFNULL (expr1, expr2)If expr1 is not NULL, the returned value of IFNULL () is expr1;Otherwise, the returned value is expr2.
After Sun was acquired by Oracle, MySQL also belongs to Oracle. However, MySQL of the Community open-source version in Ubuntu can still be installed free of charge through commands.
Before installing MySQL, update the system, open the terminal, and
First, you need a jar package to connect to Mysql.
String driver = "com. mysql. jdbc. driver "; // The URL points to the name of the database to be accessed String url =" jdbc: mysql: // 192.168.1.111: 3306/test "; // point to mysql String name =
Directory:Environment requirementsInstall MySQLChrootingConfiguration serverCommunication between PHP and MySQLAuto-start ConfigurationMySQL has become one of the most widely used databases on the network, especially for Web applications. It
The content source of this page is from Internet, which doesn't represent Alibaba Cloud's opinion;
products and services mentioned on that page don't have any relationship with Alibaba Cloud. If the
content of the page makes you feel confusing, please write us an email, we will handle the problem
within 5 days after receiving your email.
If you find any instances of plagiarism from the community, please send an email to:
info-contact@alibabacloud.com
and provide relevant evidence. A staff member will contact you within 5 working days.
A Free Trial That Lets You Build Big!
Start building with 50+ products and up to 12 months usage for Elastic Compute Service