1、用sysdba登陆sqlplus:
SQL*Plus: Release 11.2.0.1.0 Production on 星期三 12月 9 13:05:47 2020
Copyright (c) 1982, 2010, Oracle. All rights reserved.
请输入用户名: /as sysdba
连接到:
Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options
2、新建用户:
SQL> create user wlf identified by wlf;
用户已创建。
SQL> select username,user_id,account_status,default_tablespace,temporary_tablespace from dba_users where username='WLF';
USERNAME USER_ID
------------------------------------------------------------ ----------
ACCOUNT_STATUS
----------------------------------------------------------------
DEFAULT_TABLESPACE
------------------------------------------------------------
TEMPORARY_TABLESPACE
------------------------------------------------------------
WLF 85
OPEN
USERS
TEMP
3、赋予权限:
SQL> grant dba to wlf;
授权成功。
4、退出,重新登陆新用户:
SQL> exit;
从 Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production
With the Partitioning, OLAP, Data Mining and Real Application Testing options 断开
E:\BaiduNetdiskDownload>sqlplus wlf/wlf
SQL*Plus: Release 11.2.0.1.0 Production on 星期三 12月 9 14:09:13 2020
Copyright (c) 1982, 2010, Oracle. All rights reserved.
5、新建表:
SQL> create table t_wlf_component_template(
2 id number(9) not null,
3 title varchar2(20)
4 );
表已创建。
6、插入数据:
SQL> insert into t_wlf_component_template values(1,'hello world');
已创建 1 行。
7、别忘了提交:
SQL> commit;
提交完成。