MySQL Statement Specification: 1. keyword and function name all uppercase2. Database name, table name, field name all lowercase3. The SQL statement must end with a semicolon4. Comment Statement with "#"First, the operation of the database* SHOW
I. Creating a database (default character set and collation) (1) Create a database[SQL]View PlainCopy
mysql> CREATE DATABASE my_db1;
Query OK, 1 row Affected (0.00 sec)
(2) Because MY_DB1 already exists, create an error
MySQL Chinese garbled processing
Locate the My.ini file (default in the C:\ProgramData\MySQL\MySQL Server 5.7 folder);
In the My.ini:Search to [client], modify or add Default-character-set=utf8;Search to [mysqld], modify or add
MySQL Data1. Database definition language (data Definition language DDL)A. Alter DATABASEB. Create DatabaseC. Drop databased. ALTER TABLEE. CREATE tableF. drop tableG. Rename tableH. CREATE indexI. DROP Index2. Data manipulation Language (DML)A.
1. Open terminal, enter: CD ~Will enter the ~ folder2. Then enter: Touch. Bash_profileAfter the carriage return is executed,2. Re-enter: Open-e. bash_profileThis file is opened in TextEdit (this should be a blank document if the environment variable
The tests that were previously done on the latency correlation and index coverage were not recorded at the time, resulting in the recollection of forgetting some of the minutiae behind them. Today, take advantage of the impulse to revisit the test
These two days to take over, other people left the crawler found a very fun SQL script stitching.As long as your scrapy field name is the same as the name of the database field. Well, congratulations, you can copy this SQL stitching script. for
Project Address: HTTPS://GITHUB.COM/EVA911128/EXPRESS4-MICROBLOG/TREE/V1The effect is as follows:
Home:
Login page:
Registration interface:
Post-Login Interface:
After sending the content interface:
Create a new table:CREATE TABLE ' tree ' ( ' id ' int (one) not NULL auto_increment COMMENT ' primary key ', ' parent_id ' int (one) ' NOT null, ' name ' varchar (ten) not NULL, PRIMARY KEY (' id ')) engine=innodb DEFAULT Charset=utf8; Create
querying the entire contents of a data tableMysql> Show tables, #查看当前数据库下的全部表 +--------------------+| Tables_in_ceshi_ku |+--------------------+| Biao | | Ceshi_biao |+--------------------+2 rows in Set (0.00 sec) mysql> select
1, inner connection inner JOINAn inner connection, also known as an equivalent connection, inner join produces a set of data that conforms to both A and B tables.INNER JOIN syntaxSELECT * FROM A inner join B on a.name = B.name;2, natural connection
The scenario is as follows:"Today's front-end suddenly said, I need to make a judgment, can not repeat the collection, I like the neck of the icy shudder, so think what I should do?" Why did she think that I didn't think it was my job?Think of three
1.Packets larger than Max_allowed_packet is not allowedA system parameter for MySQL:max_allowed_packet, whose default value is 1048576(1M),Enquiry:show VARIABLES like '%max_allowed_packet% ';Modify the value of this variable: "max_allowed_packet =
1. Create automatic backup directories and scripts# mkdir/data/mysqlbackup/# VI backdb.shAdd the following script content#!/bin/bash/usr/local/mysql/bin/mysqldump-uacm-pacm123 acmdb >/data/mysqlbackup/acmdb_$ (Date +%y%m%d_%h%m%s). sqlTar
Different versions of MySQL optimizer have a certain difference+ View Database versionSELECT @ @version;+ View the database being usedSelect Database ();+ See if MySQL turns on slow query logShow variables like ' Slow_query_log ';+ turn on MySQL
The second day of Mysql learning, the second day of mysql
DDL database Definition Language (Database Operations) (read and understand, rarely used at work)1. Create a databaseCreate database name [character set table name collate character
Mysql storage engine and mysql StorageStorage engine Definition
The database storage engine is the underlying software organization of the database. The database management system (DBMS) creates, deletes, modifies, and queries data through the
MySQL-index details, mysql-Index
IndexIs used to quickly retrieve records with specific values. If no index exists, the database must scan the entire table from the first record until relevant rows are identified. The more data you need, the higher
Mysql exercise questions,
Table Structure and data: http://www.cnblogs.com/wupeiqi/articles/5748496.html
Question:2. query the student ID of all students whose score is higher than that of the "physical" course;1)Select A. student_id, biological
Mysql series learning, mysql Series
# HelpHelp create user;# View current userSelect user ();# Create a userCreate user 'egon' @ 'localhost' identified by '2013 ';Create user 'Alex '@' % 'identified by '201312 ';Create user 'ton '@ '192. 192. %'
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