Today’s post will introduce a new system procedure sp_databases that helps If you want to know the databases and its sizes in your db server. Its a very handy procedure that helps at times.
- If you want to know the size of log and data separately, this procedure cannot be helpful. You may refer “https://sqlzealots.com/2015/01/29/find-the-database-size-logrowtotal-in-sql-server-using-t-sql/” for the same.
- If any of databases is having more than 2.15 TB size, then sp_databases may not provide the database_size value as this column is defined as a INT datatype which can hold value upto : 2,147,483,647
If you enjoyed this blog post, please feel free to share it with your friends!