During the last two days, I did not notice that some tables were to be built on another server (the test Server database is distributed, different tables may be on different servers ). Now there is a lot of test data in it, and I don't want to add
When the website was just released, there were not many articles, and the homepage basically listed all the content. Recently there were many articles, so you need to display them by page.
The website uses the MySQL database. The code for
I. Preface:
There is a mysqld_multi command in Mysql that can be used to run multiple Mysql services on one physical server. Refer to some documents for testing and passing the command today. Now we will share the operation process with you!
Mysql databases are simple and easy to use. More and more small application systems choose mysql databases, even though mysql is free of charge.Mysql installation: Take for window as an example:Expand the installation file and execute the
When clearing a table, re-insert the data and find that the field count of the auto_increment attribute is not from 1, you can use the following command
Method 1
Delete from test;
Alter table 'test' auto_increment = 1
(Benefit, you can set
1. Create a new user:
Create user mark @ localhost identified by '20140901 ';
2. delete a user:
Drop user mark @ localhost;
3. Modify the User Name:
Rename user mark @ localhost to mark1 @ localhost;
4. Change the user password:
Set password for
This is a script that I wrote to automatically back up MYSQL. It can back up all databases in MYSQL.
#! /Bin/bash
Umask 177
MUSER = "userid"
MPASS = "password"
MHOST = "localhost"
MYSQL = "$ (which mysql )"
MYSQLDUMP = "$ (which
Master server: window XP, mysql 5.5
Slave server: window7, mysql 5.1
When starting The server slave, The system always prompts error 1200: The server is not configured as slave; fix in config file or with change master.
Use it directly on the
MySQL 5.0.37 and later versions support Profiling-official manual. This tool can be used to query how much time the SQL statement executes, how much time the System lock and Table lock take, and so on. It is very important to locate the I/O
-- Sequence management tableDrop table if exists sequence;Create table sequence (Name VARCHAR (50) not null,Current_value int not null,Increment int not null default 1,Primary key (name)) ENGINE = InnoDB; -- Function for retrieving the current
After mysql is started, log on to mysql as the root user$ Mysql-u root-p > Show variables like 'character % '; # display the code+ -------------------------- + ---------------------------- +| Variable_name | Value |+ -------------------------- + ---
The cause of the problem is very simple. You may not be able to remember it sometimes. MARK. The error message is as follows:Org. springframework. jdbc. uncategorizedSQLException: Hibernate operation: cocould not insert: [com. wondertek. meeting.
After mysql is installed, the server uses lat1 encoding by default. The procedure is as follows: Startup method:/etc/init. d/mysql. server start Effect: Database changedMysql> status--------------Mysql Ver 14.12 Distrib 5.0.77, for redhat-linux-gnu (
The remote connection to mysql fails. The error "1130-host... is not allowed to connect to this MySql server" is displayed.Authorization method. For example, if you want myuser to use mypassword to connect to the mysql server from any host. Grant
The user who uses mysqldump to back up the database requires a relatively small amount of permissions. Only the select and lock table permissions are required. Therefore, users who can create a backup database can back up the database to avoid
SELECT into outfile backup database data select email into outfile "test.txt" from email; select substring (boss,), addr from guest; load data [LOW_PRIORITY | CONCURRENT] [LOCAL] INFILE "/opt/abc.txt" into table table_name -www.2cto.com-fields
Step 1: Shut down mysql service my computer-> Manage click Management The following interface services and applications ------------> double-click the service appears, for example, find mysql service: Shut down the service. Step 2: Use software
When designing a database, we often encounter fields that indicate "no". Wang Wei, a network fisherman, encountered the following situations when designing a shop table:The store has the following attributes: first, whether it has the Consumer
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.