mysql 5.0.41 win32,mysql 服务器端(mysql-noinstall-5.0.41-win32.zip)配置步骤一览

(1) unzip mysql-noinstall-5.0.41-win32.zip into D:\

with the name mysql

(2) creat my.ini file

path:     mysql\my.ini

my.ini

---------------------------------------------

[WinMySQLAdmin]

Server=D:\mysql\bin\mysqld-nt.exe

[mysqld]

basedir=D:\mysql

datadir=D:\mysql\data

----------------------------------------------

(3)

MS-Dos    operator:

(a):cd ->     D:\mysql\bin

mysqld --install mysql --defaults-file= D:\mysql\my.ini

(4)

net start mysql

(5)

net stop mysql

(6)

sc delete mysql

(7)common cmd

(a)change password

//meng is old password and mengsj is your new's

mysqladmin -u root -pmeng password mengsj

//mengsj is old password and "" is your new's

mysqladmin -u root -pmengsj password ""

(b)login

mysql -u root -p

mysql -h localhost -u root -p

(c)login with the name root,then you can do the operators

//create new user

//all databases and the user name is test2 and password is password

grant select,insert,update,delete on *.* to test2@"%" Identified by "password"

//database which named test02 and the user name is test2 and password is password

grant select,insert,update,delete on test02.* to test2@localhost identified by "password"

//set the root's password with    ""

grant select,insert,update,delete on *.* to root@localhost identified by "";

(8) examples

select now(), user(),version();

//cancle the cmd

\c

//see the databases you can operator

show databases;

//select the database you want to operator

select database();

//see the tables you can operator

show tables;

//create database

create database test02;

//select the database you want to operator

use test02;

create table testtb001(

last_name    varchar(15) not null,

first_name varchar(15) not null,

city         varchar(15) not null,

birth        date          not null,

death        date          null

);

create table testtb002(

password    varchar(20) not null);

insert into testtb002(password) values ('aaa');

commit;

select * from testtb002;

评论
添加红包

请填写红包祝福语或标题

红包个数最小为10个

红包金额最低5元

当前余额3.43前往充值 >
需支付:10.00
成就一亿技术人!
领取后你会自动成为博主和红包主的粉丝 规则
hope_wisdom
发出的红包
实付
使用余额支付
点击重新获取
扫码支付
钱包余额 0

抵扣说明:

1.余额是钱包充值的虚拟货币,按照1:1的比例进行支付金额的抵扣。
2.余额无法直接购买下载,可以购买VIP、付费专栏及课程。

余额充值