Home > Database > Mysql Tutorial > Oracle 查看特定用户所拥有的表

Oracle 查看特定用户所拥有的表

WBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWBOYWB
Release: 2016-06-07 17:00:17
Original
982 people have browsed it

注意:all_objects视图也可以查看当前特定用户所有的表, 但是这个视图里面不光只有table,还有其他的该用户所拥有的对象 如:

1.普通用户下  
  1.1查看user_tables视图  
  select table_name from user_tables;  
  TABLE_NAME  
  ------------------------------  
  PROJECT_MANAGE  
  SALGRADE  
  BONUS  
  EMP  
  DEPT  
  //  
  1.2查看all_tables视图[sysdba用户下,或者普通用户都可以查看]  
  select table_name from all_tables where owner='SCOTT';  
  TABLE_NAME  
  ------------------------------  
  DEPT  
  EMP  
  BONUS  
  SALGRADE  
  PROJECT_MANAGE  
  //  
2.sysdba权限下  
  查看dba_tables视图  
  select table_name from dba_tables where owner= 'SCOTT';  
  TABLE_NAME  
  ------------------------------  
  DEPT  
  EMP  
  BONUS  
  SALGRADE  
  PROJECT_MANAGE  
  //  
注意:all_objects视图也可以查看当前特定用户所有的表,  
但是这个视图里面不光只有table,,还有其他的该用户所拥有的对象  
如:view,primary key,foreign key,procedure,function,sequence,... 

linux

Related labels:
source:php.cn
Statement of this Website
The content of this article is voluntarily contributed by netizens, and the copyright belongs to the original author. This site does not assume corresponding legal responsibility. If you find any content suspected of plagiarism or infringement, please contact admin@php.cn
Popular Tutorials
More>
Latest Downloads
More>
Web Effects
Website Source Code
Website Materials
Front End Template