随笔分类 - oracle / 常用命令
日常使用SQL
摘要:col owner format a20 col object_id format 99999999 col object_name format a30 col object_type format a30 col column_name format a30 col table_name for
阅读全文
摘要:SQL> desc gv$instance; Name Null? Type INST_ID NUMBER INSTANCE_NUMBER NUMBER INSTANCE_NAME VARCHAR2(16) HOST_NAME VARCHAR2(64) VERSION VARCHAR2(17) ST
阅读全文
摘要:查看数据库连接主机名,程序名,用户名等情况 select b.MACHINE, b.PROGRAM, b.USERNAME, count(*) from v process a, vprocessa,vsession b where a.ADDR = b.PADDR and b.USERNAME i
阅读全文
摘要:col owner format a20 col object_name format a50 set linesize 100 select owner,object_name from dba_objects where owner='ORDDATA' and object_type='TABL
阅读全文
摘要:1、查找表的所有索引(包括索引名,类型,构成列): select t.*,i.index_type from user_ind_columns t,user_indexes i where t.index_name = i.index_name and t.table_name = i.table_
阅读全文
摘要:col sid format 9999 col spid format 9999999999 col serial# format 9999999 col logon_time format a20 col machine format a30 col terminal format a20 set
阅读全文
摘要:v$session常用字段如下 SID SERIAL# SPID SQL_ID STATUS ROW_WAIT_OBJ# BLOCKING_SESSION_STATUS  SID NUMBER SERIAL# NUMBER AUDSID NUMBER PADDR RAW(8) USER# NUMBER USERNAME VARCHAR2(30) COMMAND
阅读全文
摘要:expdp expuser/oracle parfile=exptable.par content=metadata_only cluster=n 编辑exptable.par文件 more exptable.par dumpfile=mdm.dmp logfile=mdm.log schemas=
阅读全文