MySQL Database learning experience (2)

Source: Internet
Author: User
Tags exit copy flush mysql database

(ii) installation under Windows2000

1. Select default directory when installing: C:mysql

2. Take c:mysqlmy-example.cnf copy for c:my.cnf, and C:mysqlibgwinb19.dll copy to Winntsystem32.

3. The way to start MySQL is:

C:mysqlinmysqld-shareware--install

net start MySQL

So simple, it can be started.

4. To change the password for superuser (root):

C:mysqlinmysql MySQL

mysql> UPDATE user SET password=password (' Your password ') swheresuser= ' root ';

Mysql> QUIT

C:mysqlinmysqladmin Reload

Use the command c:mysqlinmysqlshow to take a look at the test. You should show here:

+-----------+

| Databases |

+-----------+

| MySQL |

| Test |

+-----------+

Seeing this information, this step proves it's okay.

Again:

C:mysqlinmysqlshow--user=root--password=your Password MySQL

You should show here:

Database:mysql

+--------------+

| Tables |

+--------------+

| Columns_priv |

| db |

| Host |

| Tables_priv |

| user |

+--------------+

Everything's done!

5. C:mysqlinmysqladmin Version Status proc

You should be able to see these version information:

Mysqladmin Ver 8.0 distrib 3.22.32, for Win95/win98 on i586

TCX datakonsult AB , by Monty

Server version 3.22.32-shareware-debug

Protocol version 10

Connection localhost via TCP/IP

TCP Port 3306

Uptime:1 Hour sec

Threads:1 questions:72 Slow queries:0 opens:16 Flush tables:1 Open tables:0 Memory in use:16423k Max Memory US ed:16490k

uptime:5370 threads:1 questions:72 Slow queries:0 opens:16 Flush tables:1 Open tables:0 Memory in use:16423k M Ax Memory used:16490k

+----+------+-----------+----+---------+------+-------+------------------+

| Id | User | Host | db | Command | Time | State | Info |

+----+------+-----------+----+---------+------+-------+------------------+

| 35 | ODBC | localhost | | Query | 0 | | Show Processlist |

+----+------+-----------+----+---------+------+-------+------------------+

Next, use the show databases command to list the installed databases:

mysql> show databases;

Then you can see:

+----------+

| Database |

+----------+

| MySQL |

| Test |

+----------+

2 rows in Set (0.00 sec)

If everything is OK, it means that MySQL can work completely! If you want to exit the program, enter: Exit

Mysql> exit;

Bye



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.