Get the App
SLTechnology News&Howtos  ›  Database  › 

Use cmd to enter mysql

Shulou Source: shulou.com Published: 2022-06-01 03:30:27 09月30日 Update

This article mainly introduces the use of cmd to enter mysql, the article is very detailed, has a certain reference value, interested friends must read it!

Procedure:

1. Open [start] "[run] enter [cmd] and click [OK] the CMD command black window appears, which is what we call the CMD command line, or use the shortcut key Windows (a key with a Windows logo on the keyboard) + R to enter cmd and enter.

two。 Type a command in the CMD command window

Mysql-hlocalhost-uroot-p

Press enter (note that the "- h", "- u" and "- p" here cannot be omitted) to enter the mysql database, where "- h" represents the server name, localhost represents the local; "- u" is the database user name, root is the default MySQL user name; "- p" is the password, if you set the password, you can directly enter the link after-p, such as:-p888888, the user does not set a password, display Enter password, you can directly enter.

Note that if your MySQL is not installed on disk C, use the DOS command to enter the bin directory under the installation directory of MySQL. The method is as follows: enter G: enter G disk), enter cd G:\ phpstudy\ mysql\ bin to enter the bin directory of MySQL, then enter mysql-hlocalhost-uroot-p and press enter.

The above is all the content that uses cmd to enter mysql, thank you for reading! Hope to share the content to help you, more related knowledge, welcome to follow the industry information channel!

Tags: Input command password user directory content data database user name value interest enter key boy buddy that is shortcut keys keys methods more server Apple Docker Huawei Linux macOS MariaDB Microsoft MySQL NVidia OPPO Reno vpn Xiaomi Huawei Redmi OPPO Reno