mysql啟動與新建使用者

2021-08-14 08:02:41 字數 1166 閱讀 3033

net start mysql;啟動

net stop mysql;關閉

mysql - h localhost -u root -p

密碼連線

select @@global.tx_ioslation,@@tx_ioslation;

檢視系統預設隔離級別,當前會話隔離級別

set global transaction isolation level read committed;設定系統隔離級別

set session transaction isolation level read committed;設定當前隔離級別

show databases;顯示所有的資料庫

drop database dadreaming;

create database 名字

set password=password('code');設定密碼

select now();當前系統時間日期

desc 表名

show columns from

檢視表結構

rename table 原表名 to 新錶名;

select * from tdb_goods grid\g;單行輸出

drop table 名

建立表:

mysql> create table myclass

-> (

id int(4) not null primary key auto_increment,

name varchar(20) not null,

*** int(4) not null default '0',

degree double(16,2));

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

增加新使用者

一、此方法必須同時開啟兩個視窗,適用於臨時登入

二、方法2

mysqld --initialize-insecure

mysqld install

net start mysql

use mysql

set password=password('1234')

mysqld --initialize-insecure

Mysql新建使用者與許可權

create user oneapm localhost identified by yourpassword grant process,replication client on to oneapm localhost with max user connections 5 grant sele...

Mysql新建使用者操作

方法一 mysql insert into mysql.user host,user,password values localhost zhangs password 123456 mysql flush privileges 解釋 這樣就建立了乙個使用者名為zhangs,密碼為123456的資料...

mysql會新建使用者嗎 mysql建立使用者

1.mysql set password for test78115cn password 更改使用者密碼的命令 2.客戶資料在 cd usr local mysql var 注意如果您是 cd usr local mysql 那麼請不要再 cd var 而是cd var 系統有兩個檔案的。測試可否...