1
After installing MySQL, change the root password and use
NET Startmysql
I ran into this problem when I started. After you use the following command
C:\mysql\bin\mysqladmin-u root-p shutdown
Again net start MySQL does not have this error hint!
***
Two modes of update injection (mysql+php)
Article/Security Angel · Superhei 2005.8.11
A. Test environment:
Os:windowsxp SP2
php:php 4.3.10 (
MySQL 4.1.9
Apache 1.3.33
Two. Test database structure:
-----Start---
--Database: ' Test '
--
-- ----------
Change the default MySQL database directory
Change the C:\ProgramData\MySQL\MySQL Server 5.1\data to D:\MysqlData
1. Create a folder D:\MysqlData
2. Stop MySQL service, copy "C:\ProgramData\MySQL Server 5.1\data" All files to D:\MysqlData
3.
About node.js operation MySQL Database related introduction Please read the full text. The details below are described below, as follows:
Installing the MySQL module
Database Preparation
MySQL server is located in the machine IP
We use MySQL query when the normal is directly a table query, or that is, multiple tables of the associated query, use to the left-join (right) join, the inner join, the outer join (outer join). This is a certain correlation between two tables, that
Let's start by creating a table authors:
CREATE TABLE Authors (
authid SMALLINT not NULL PRIMARY KEY,
authfn VARCHAR (),
authmn VARCHAR ()
AUTHLN VARCHAR
)
Engine=innodb;
Then insert more than one piece of data into the table, and the
1, open Mysql.exe (MySQL Command line Client), enter the password
2, input: use MySQL;
3, query host input: Select User,host from User;
4, create the host (if there is "%" the host value, then skip this step)
If there is no "%" host value,
I am for the classmate to do a Java-ee about the struct+hibernate structure of the class, the database used to be Oracle, the database is missing, do not want to install Oracle, that thing installed in the book too knife, can not remove nausea ...
In MySQL database development, we sometimes need to copy or copy a table structure and data to the exception of a table, this time we can use the create ... from statement to implement, this article introduces you to the MySQL replication table
In MySQL, indexes can be divided into two types of hash index and Btree index.
Under what circumstances can I use a B-tree index?
1. Full Value Matching index
Like what:
Orderid= "123"
2. Matching the leftmost prefix index query
For example,
This article illustrates the method of creating, deleting, and modifying a table for MySQL learning notes. Share to everyone for your reference, specific as follows:
To create a table:
CREATE TABLE users (
ID int,
name varchar (),
sex
First step:
1: Disk seek ability to high speed hard drive (7200 rpm), theoretically seek 7,200 times per second. There is no way to change, the optimization method is to----with multiple hard drives, or to spread data storage.
2: Read and write
MySQLdb default query results are returned tuple, the output time is not very convenient, you must follow the 0,1 so read, inadvertently found on the internet a simple way to modify, is to pass a cursors. Dictcursor on the line.
Default
For example, table: event (id int () auto_increment primary KEY,Sid Int (a) NOT NULL,Detail text)
I would like to delete the SID duplicate record in the table event, is there such an SQL statement? or by other means?
Copy Code code as follows:
Because mysqldump will add a global lock to the entire library.
A full-library backup with Mysqldump will have the following three effects.
1, the server CPU seriously blocked.
2, disk I/O line increase.
3, all the queries have become a slow
There may be such a value array (' A ' = ' B ') in the datasheet when the database is backed up.
' C ' = ' d ')
The value of this format. When the data is exported, the newline is changed to \ n (this is the case under Windows, which may be another
Option Default-charaset-set=utf8;
It then creates a datasheet create TABLE a_table (b varchar (255) not NULL);
INSERT into a_table values (' Beijing ');
This time is inserted in Chinese and the system will report an error: Incorrect string
So to
Copy Code code as follows:
Create_time datetime default Now ()
It is not possible to set the default value in the form.
The alternative is to use the timestamp type instead of the datetime type.
Current_timestamp: When I
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