请输入用户名: system 输入口令: 连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> select * from v$version where rownum=1; BANNER -------------------------------------------------------------------------------- Oracle Database 11g Enterprise Edition Release 11.2.0.1.0 - 64bit Production SQL> show user; USER 为 "SYSTEM" SQL> grant dba to scott 2 ; 授权成功。 SQL> alter user scott account unlock; 用户已更改。 SQL> alter user scott identified by 1234; 用户已更改。 SQL> conn scott/1234; 已连接。 SQL> create table test as select * from dba_objects; 表已创建。
SQL> select count(*) from test;
COUNT(*)
----------
72699
SQL> desc test;
名称 是否为空? 类型
----------------------------------------- -------- ----------------------------
OWNER VARCHAR2(30)
OBJECT_NAME VARCHAR2(128)
SUBOBJECT_NAME VARCHAR2(30)
OBJECT_ID NUMBER
DATA_OBJECT_ID NUMBER
OBJECT_TYPE VARCHAR2(19)
CREATED DATE
LAST_DDL_TIME DATE
TIMESTAMP VARCHAR2(19)
STATUS VARCHAR2(7)
TEMPORARY VARCHAR2(1)
GENERATED VARCHAR2(1)
SECONDARY VARCHAR2(1)
NAMESPACE NUMBER
EDITION_NAME VARCHAR2(30)
参考资料:《SQL优化核心思想》罗炳森 黄超 钟侥等著 P3 本书约定处