Home >Backend Development >PHP Tutorial >Getting Started with MySQL (1)_PHP Tutorial
Installation
PHP MySQL Linux has gradually become a classic combination of small web servers. Building and debugging MySQL database in Windows environment is the first choice of many website developers. I am new to MySQL in Windows 98 environment, and now I will summarize the learning process and experience for your reference.
1. Download mysql-3.23.35-win.zip and unzip it;
2. Run setup.exe; select d:mysql, "tyical install"
3. Start mysql, the following methods are available:
Method 1: Use winmysqladmin
1). Enter the d::mysql in directory and run winmysqladmin.exe. There will be a red icon in the taskbar in the lower right corner of the screen
2). Use the mouse Left-click the icon, select "show me", and the "WinMySQLAdmin" operation interface will appear; when running for the first time, a dialog box will appear in the middle asking to enter and set your user name and password
3), select "My.INI setup”
4), select “mysqld-opt” (win9x) or “mysqld-nt” (winNT) in “mysqld file”
5), select “Pick-up or Edit my.ini values” You can edit your my.ini file in the right window
6). Select "Save Modification" to save your my.ini file
7) If you want to use winmysqladmin quickly (run automatically when booting) , select "Create ShortCut on Start Menu"
8), test:
Enter the DOS interface;
Run mysql in the d:mysql in directory, enter the mysql interactive operation interface
Enter show databases and Press Enter, and the screen displays the two existing databases mysql and test
Method 2: Do not use winmysqladmin
1). In the DOS window, enter the d:/mysql/bin directory
2). Run under win9X:
mysqld
Run under NT:
mysqld-nt --standalone
3). After that, mysql runs in the background
4). Test mysql: (In the d:/mysql/bin directory)
a), mysqlshow
Displays the existing two databases mysql and test when normal
b), mysqlshow -u root mysql
Displays normally Five tables in the database mysql:
columns_priv
db
host
tables_priv
user
c), mysqladmin version status proc
displays version number, status, process information, etc.
d), mysql test
Enter the mysql operation interface, the current database is test
5), mysql shutdown method:
mysqladmin -u root shutdown
4. At this point, MySQL has been successfully installed. Then you can become familiar with the common commands of MySQL and create your own database.