How to get all table and view connection in oracle?

by lindsey.homenick , in category: Third Party Scripts , a month ago

How to get all table and view connection in oracle?

Facebook Twitter LinkedIn Telegram Whatsapp

1 answer

Member

by denis , 25 days ago

@lindsey.homenick 

To get all table and view connections in an Oracle database, you can query the system views USER_TABLES and USER_VIEWS. Here is a sample SQL query that can retrieve this information:

1
2
3
4
5
6
7
SELECT table_name, view_name 
FROM (
    SELECT table_name, null as view_name FROM user_tables
    UNION ALL
    SELECT null as table_name, view_name FROM user_views
)
ORDER BY table_name, view_name;


This query will return a list of all tables and views in the database, along with their connections. You can modify the query to include more information or filter the results as needed.