Count user name : Usename « SQL PLUS Session Environment « Oracle PL/SQL Tutorial






SQL>
SQL> SELECT COUNT(username) users, default_tablespace
  2  FROM dba_users
  3  where rownum<50
  4  GROUP BY default_tablespace
  5  /

     USERS DEFAULT_TABLESPACE
---------- ------------------------------
         6 SYSAUX
         2 USERS
         7 SYSTEM

SQL>








29.58.Usename
29.58.1.SELECTs using the GROUP BY clause.
29.58.2.Count user name