/*获取 Oracle 版本*/SELECT VALUEFROM v$system_parameter WHERE name = 'compatible'; /*在视图中查询并显示实际的 Oracle 连接*/SELECT osuser,username,machine, program FROM v$session /*where machine = 'PC-20140604AMGV' */ORDER BY osuser; /*查询并显示连接 Oracle 的用户和用户的会话数量*/SELECT username, COUNT (username) sessionCountFROM v$session where username is not nullGROUP BY usernameORDER BY sessionCount DESC;
?