CodePudding user response:
SQL> The SELECT DBMS_METADATA. GET_DDL (' TABLE ', 'EMP) FROM DUAL;DBMS_METADATA. GET_DDL (' TABLE ',
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
CREATE TABLE "PEC". "EMP"
(" EMPNO NUMBER (4, 0),
"ENAME" VARCHAR2 (10) CONSTRAINT "BIN $VD4eNL77NVrgU4BkYApSLw==$0" the NOT NULL ENABL
"JOB" VARCHAR2 (9),
"MGR" NUMBER (4, 0),
"HIREDATE" DATE DEFAULT SYSDATE,
"SAL" NUMBER (7, 2),
"COMM" NUMBER (7, 2),
"DEPTNO NUMBER (2, 0),
"COMMENTS" VARCHAR2 (300),
The CONSTRAINT "BIN $VD4eNL76NVrgU4BkYApSLw==$0" PRIMARY KEY (" EMPNO ")
USING the INDEX PCTFREE 10 INITRANS 2 MAXTRANS 255 COMPUTE STATISTICS
1 the MAXEXTENTS STORAGE (INITIAL 65536 NEXT 1048576 MINEXTENTS 2147483645
PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
In TABLESPACE ENABLE "DRP",
The CONSTRAINT "FK_DEPTNO" FOREIGN KEY (" DEPTNO ")
The REFERENCES "PEC". The "DEPT" (" DEPTNO ") ENABLE
) the SEGMENT CREATION IMMEDIATE
PCTFREE 10 PCTUSED 40 INITRANS 1 MAXTRANS 255
NOCOMPRESS LOGGING
1 the MAXEXTENTS STORAGE (INITIAL 65536 NEXT 1048576 MINEXTENTS 2147483645
PCTINCREASE 0 FREELISTS 1 FREELIST GROUPS 1
BUFFER_POOL DEFAULT FLASH_CACHE DEFAULT CELL_FLASH_CACHE DEFAULT)
In TABLESPACE "DRP
"
SQL> Desc emp;
The Name Type Nullable Default Comments
-- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- -- --
EMPNO NUMBER (4)
ENAME VARCHAR2 (10)
JOB VARCHAR2 (9) Y
MGR NUMBER (4) Y
HIREDATE DATE Y SYSDATE
SAL NUMBER (7, 2) Y
COMM NUMBER (7, 2) Y
DEPTNO NUMBER (2) Y
Y COMMENTS VARCHAR2 (300)
CodePudding user response:
Can query the col, user_tab_columns, these two views,CodePudding user response:
Select * from all_tab_columns where table_name='EMP;