|
|
|||||||||
|
|||||||||
| |||||||||
|
|
|
| |||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
Check Oracle View Exist or not
What the command should be if I want to check the view exists or not?
__________________
Real, Nice and Beautiful are my hungry for knowledges. |
|
#2
|
|||
|
|||
|
Run the query against dba_objects or dba_views,
dba_objects view keeps the information of all object created in the database and show the current status of object also, if any view or package body has some compilation problem then status would be 'INVALID' means view is exist but you can't run any query. SELECT * FROM dba_objects WHERE object_name = 'DBA_OBJECTS' AND OBJECT_TYPE = 'VIEW' / dba_views keeps the information about only views those are exist in the database as well as the view query/definition also, if you forget that how did you create this view, you can see the query of this view by running query against dba_views. SELECT * FROM dba_views WHERE view_name = 'DBA_OBJECTS' / you might have some aother views also with less information like, user_views, and user_objects. |
|
#3
|
|||
|
|||
|
You can also use the ALL_VIEWS view, which usually allows SELECT for all users,
DBA_VIEWS may not. Check with your DBA. |
![]() |
| Viewing: Dev Shed Forums > Databases > Oracle Development > Check Oracle View Exist or not |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|