Start: net start MySQL;Enter: Mysql-u root-p/mysql-h localhost-u root-p databaseName;List database: show databases;Select database: Use DatabaseName;List table: Show tables;Displays the properties of the table column: Show columns from
1. Introduction This is a guide to how we use the Pear db extension. Pear DB, which provides a series of classes:
N Database Abstraction
N Advanced error handling mechanism
N and other
2. Download and install Pear
Since the Pear project is still
MySQL Database Usage Summary
This article mainly records some MySQL daily use of the commands for future inquiries.
1. Change root password
Mysqladmin-uroot password ' yourpassword '
2. Remote login MySQL Server
Mysql-uroot-p-hip-p3306
3.
As for the database in the Web programming, the function of the database is more and more cannot be neglected. Referring to the database, it should be said that PHP has very strong database support capabilities, from FileMaker to Oracle, almost all
The functionality of Redis is really powerful and can be done as a database and can be cached.Today, Redis supports the separation of operational space, which makes space and space non-impact.SELECT IndexSwitches to the specified database, and the
Laravel 5.1 Sub-query instances
Native sql:
Select COUNT (UID) as Onl,date_format (time, '%H ') as hour from ' d_user_login201705 ' where ' id ' in (select min (id) as Mid fro M ' d_user_login201705 ' where ' type ' = ' 0 ' and ' time ' >= ' 2017-05-
First of all, the Laravel framework to query and print the SQL statements, regardless of any time due to the SQL statement error, you can print first, analyze the cause of the error① Introduction of Laravel Framework DB Class Use Illuminate\support\
MySQL create user and authorizeCreate User: Grant all on . to ' user1 ' @ ' IP address ' identified by ' passwd '; (User1 can be a custom user name, passwd is a password.) )Grant to a user: Grant Select,update,insert on db1.* to ' user name ' @ '
One, MySQL user managementGrant all on * * to ' user1 ' @ ' 127.0.0.1 ' identified by ' mimA123 '; Create User1 userSign in with User1/usr/local/mysql/bin/mysql-uuser1-pmima123-h127.0.0.1To localhost, without-H can also log inMysql> Grant All on * *
"Pt-table-checksum"Pt-table-checksum is one of the Percona-toolkit series tools that can be used to detect the consistency of the data in the master and from the database. The principle is to run on the main library, checksum the synchronized tables
AggregateThe Query Builder also provides a variety of aggregation methods, such as,, count max min , avg and sum .Using Aggregation Methods #$users=Db::Table(' Users ')->Count();$price=Db::Table(' Orders ')->Max(' Price ');$price=Db::Table(' Orders
This article mainly discusses a few questions:(1) When the data in the database and the cache is inconsistent(2) Inconsistent optimization ideas(3) How to ensure the consistency of database and cacheFirst, the origin of demandThe previous article,
This article mainly discusses a few questions:(1) When the data in the database and the cache is inconsistent(2) Inconsistent optimization ideas(3) How to ensure the consistency of database and cachefirst, the origin of demandThe previous article,
Root password for MySQL/usr/local/mysql/bin/mysqladmin-uroot password ' [password] ' Set password/usr/local/mysql/bin/mysqladmin-uroot-p ' [Original password] ' password ' [New password] ' Set passwordIf you do not know the password, reset the
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.