Oracle:查看用户信息(dba_users)
以下SQL将按照Oracle中,账户被创建的时间先后排序:
1 2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 22 23 24 25 26 27 28 29 30 31 32 33 34 35 36 37 38 39 40 41 42 43 44 45 46 47 48 49 50 51 52 53 54 55 56 57 58 59 60 61 62 63 |
PS C:\Users\adamhuan> sqlplus / as sysdba SQL*Plus: Release 11.2.0.3.0 Production on 星期日 5月 17 00:16:16 2015 Copyright (c) 1982, 2011, Oracle. All rights reserved. 连接到: Oracle Database 11g Enterprise Edition Release 11.2.0.3.0 - 64bit Production With the Partitioning, OLAP, Data Mining and Real Application Testing options SQL> SQL> set linesize 900 SQL> set pagesize 900 SQL> SQL> select username,account_status,default_tablespace,to_char(created,'yyyy-mm-dd hh24:mi:ss') from dba_users order by created desc; USERNAME ACCOUNT_STATUS DEFAULT_TABLESPACE TO_CHAR(CREATED,'YY ------------------------------ -------------------------------- ------------------------------ ------------------- J OPEN USERS 2015-05-17 00:13:16 ANGELABABY OPEN USERS 2015-05-14 11:59:48 ALLAH OPEN USERS 2015-05-14 11:59:20 ADAMHUAN OPEN USERS 2015-05-14 11:58:48 BI EXPIRED & LOCKED USERS 2015-05-14 11:34:48 PM EXPIRED & LOCKED USERS 2015-05-14 11:34:48 HR EXPIRED & LOCKED USERS 2015-05-14 11:34:47 OE EXPIRED & LOCKED USERS 2015-05-14 11:34:47 IX EXPIRED & LOCKED USERS 2015-05-14 11:34:47 SH EXPIRED & LOCKED USERS 2015-05-14 11:34:47 SCOTT EXPIRED & LOCKED USERS 2011-11-03 06:39:35 OWBSYS_AUDIT EXPIRED & LOCKED SYSAUX 2011-11-03 06:38:07 OWBSYS EXPIRED & LOCKED SYSAUX 2011-11-03 06:38:03 APEX_030200 EXPIRED & LOCKED SYSAUX 2011-11-03 06:21:18 APEX_PUBLIC_USER EXPIRED & LOCKED USERS 2011-11-03 06:21:18 FLOWS_FILES EXPIRED & LOCKED SYSAUX 2011-11-03 06:21:17 MGMT_VIEW OPEN SYSTEM 2011-11-03 06:19:13 SYSMAN OPEN SYSAUX 2011-11-03 06:14:42 SPATIAL_CSW_ADMIN_USR EXPIRED & LOCKED USERS 2011-11-03 06:14:17 SPATIAL_WFS_ADMIN_USR EXPIRED & LOCKED USERS 2011-11-03 06:14:09 MDDATA EXPIRED & LOCKED USERS 2011-11-03 06:09:35 OLAPSYS EXPIRED & LOCKED SYSAUX 2011-11-03 06:08:22 ORDPLUGINS EXPIRED & LOCKED SYSAUX 2011-11-03 06:02:21 SI_INFORMTN_SCHEMA EXPIRED & LOCKED SYSAUX 2011-11-03 06:02:21 MDSYS EXPIRED & LOCKED SYSAUX 2011-11-03 06:02:21 ORDSYS EXPIRED & LOCKED SYSAUX 2011-11-03 06:02:21 ORDDATA EXPIRED & LOCKED SYSAUX 2011-11-03 06:02:21 XS$NULL EXPIRED & LOCKED USERS 2011-11-03 06:01:56 ANONYMOUS EXPIRED & LOCKED SYSAUX 2011-11-03 05:59:56 XDB EXPIRED & LOCKED SYSAUX 2011-11-03 05:59:56 CTXSYS EXPIRED & LOCKED SYSAUX 2011-11-03 05:59:18 EXFSYS EXPIRED & LOCKED SYSAUX 2011-11-03 05:59:02 WMSYS EXPIRED & LOCKED SYSAUX 2011-11-03 05:51:21 APPQOSSYS EXPIRED & LOCKED SYSAUX 2011-11-03 05:49:39 DBSNMP OPEN SYSAUX 2011-11-03 05:49:37 ORACLE_OCM EXPIRED & LOCKED USERS 2011-11-03 05:42:44 DIP EXPIRED & LOCKED USERS 2011-11-03 05:41:45 OUTLN EXPIRED & LOCKED SYSTEM 2011-11-03 05:39:21 SYS OPEN SYSTEM 2011-11-03 05:39:19 SYSTEM OPEN SYSTEM 2011-11-03 05:39:19 已选择40行。 SQL> |
——————————————————————————————————————
Done。