mysql中建立使用者和賦許可權

2022-03-04 19:43:13 字數 651 閱讀 2461

1. 建立oozie使用者,%符號表示僅限於遠端登入

create

user

'oozie

'@'%

' identified by

'password

';

2. 賦予許可權

all指所有功能,如果all被替換為select,則只有查詢功能。

on後面的oozie指資料庫名稱

to後面oozie指賬號,很簡單。

grant

allon oozie.*to'

oozie

'@'%

';

20190101: 今天get一招

如果想用某個賬戶給某個資料庫指定許可權,這樣來操作,之前在使用上面操作時總是提示各種各樣奇怪的許可權錯誤:

grant

allprivileges

on ecsoft.*to'

ecsoft

'@'%

' identified by

'password

'with

grant

option

;flush

privileges;

如果該賬號之存在過,請先刪除後再新增。

mysql給使用者賦許可權

mysql grant 許可權1,許可權2,許可權n on 資料庫名稱.表名稱 to 使用者名稱 使用者位址 identified by 連線口令 例子 grant all privileges on to root localhost identified by root 許可權1,許可權2,許可...

Oracle 建立使用者 及賦許可權

create temporary tablespace test temp tempfile opt oracle oradata orcl pelt01.dbf size 6000m autoextend on next 500m maxsize 10000m extent management ...

mysql 賦許可權 MySQL賦予使用者許可權命令總結

mysql使用者可用許可權 乙個新建的mysql使用者沒有任何訪問許可權,這就意味著你不能在mysql資料庫中進行任何操作。你得賦予使用者必要的許可權。以下是一些可用的許可權 all 所有可用的許可權 create 建立庫 表和索引 lock tables 鎖定表 alter 修改表 delete ...