If you want to get the size of each table in each database on the instance, run the following script – Below part of the
More significant for Azure SQL Database to determine who all are connected from which IP address and how many connections sys.dm_exec_sessions and sys.dm_exec_connections
This is similar to what we saw in SQL Script to Check Most Executed Queries in a SQL Server Database post with the difference that
sys.dm_exec_query_stats sys.dm_exec_sql_text to fetch the exact query sys.dm_exec_query_plan to fetch the query plan And again Thanks to Glenn Berry for sharing the script.
sys.indexes, sys.objects and sys.dm_db_index_usage_stats Checks where writes are greater than the reads i.e. index maintenance is higher than the benefit it is serving during read
sys.partitions and sys.objects Consider ONLY Heap or Clustered Index that gives you the count Thanks to Glenn Berry for sharing the script.
When was the last time statstics were updated for a particular index You can filter it as per you needs to run it faster or
This may take some time to get executed if the database size is large You may filter it for some specific cases to run it