Some of MySQL's operations

Source: Internet
Author: User
Tags create database

Servives.msc the computer service to run, you can check the MySQL boot situation.


net stop MySQL stop MySQL run
net start MySQL startup MySQL

Note: Sometimes it takes an administrator's identity, otherwise it doesn't work.

There are two ways of doing this:
1 Connect to database: mysql-u+ user name-p+ user password-hlocalhost-p3306 (not local-H and-P)
mysql-uroot-padmin-h127.0.0.1-p3306

If you are accessing locally, you do not need to add-H and-p

2 after the installation of MySQL will automatically produce a command window, can be used directly.


Open the database service:
show databases;
Use a database:
Use database MySQL;
To view the tables for the database:
Show tables;
Create a new database:
Create Database demobase;
To delete a database:
Drop database demobase;

Note the semicolon ";".

Some of MySQL's operations

Related Article

Contact Us

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

  • Sales Support

    1 on 1 presale consultation

  • After-Sales Support

    24/7 Technical Support 6 Free Tickets per Quarter Faster Response

  • Alibaba Cloud offers highly flexible support services tailored to meet your exact needs.