Finding objects referenced in SQL query
I have a pretty complex query to analyze for a performance issue. There are a lot of sub queries, the SQL text goes on for two pages and the execution plan is 171 row sources. A cursory look at the plan shows some full table scans where I know the selectivity in that query block is high. I would like to handle any low hanging fruit first. I want to get a list of tables used in this query so I can check the last time their stats were collected. I also want to get a list of any views