where can I find the data growth for a database per week or per month?
I want to know how big the database was on 7/31/2011. Then, I wnat to know how big it was on 7/1/2011. I can subtract 7/1/2011 for 7/31/2011 and know how much my Db has grown.JDowling
August 25th, 2011 5:10pm

Hi Joseph, Please go through the following articles to get started - How to track database growth across multiple SQL Server instances - http://weblogs.sqlteam.com/tarad/archive/2008/12/16/How-to-track-database-growth-across-multiple-SQL-Server-instances.aspx How to track database file growth over a period of time - http://vyaskn.tripod.com/track_sql_database_file_growth.htm Hope this helps!
Free Windows Admin Tool Kit Click here and download it now
August 25th, 2011 5:52pm

A couple people have sent me this. One of the links is broken, and the other wants to create another table to track the backup files. I tried it, but it wasn't the solution for me. I ended up writing a query to just go into the itedatapages on my SQL server and use the dbname. What I would like to do with this is to script it to read in the Db name and store it as a variable so I can recurse through multiple databses. My code use dbname set nocount on SELECT CAST((ISNULL(SUM(CAST(hsi.itemdatapage.filesize AS Numeric(15,4))),0)/1024/1024/1024) AS NUMERIC(15,6)) as Storage FROM hsi.itemdata, hsi.itemdatapage, hsi.doctype WHERE hsi.itemdata.itemnum = hsi.itemdatapage.itemnum AND hsi.doctype.itemtypenum = hsi.itemdata.itemtypenum --AND hsi.doctype.itemtypenum > 100 --exclude system docs --AND hsi.doctype.itemtypename NOT LIKE 'zzz%' --uncomment the line below for a date range and datestored between '7/1/2011 12:00 am' and '7/30/2011 11:59:59 pm' The 1024/1024/1024 returns the data in Gb, 15,6 gives my boss 6 decimal places to calculate. On some of these queries I have to format them 1024/1024/1024.0 so it forces it to be decimal. If the answer is smaller than zero (0), it will just return zero (0) if I don't do that. JDowling
August 30th, 2011 9:38am

This topic is archived. No further replies will be accepted.

Other recent topics Other recent topics