• Thanks for the great script. I created a table with a capture date and put your script (with some minor modifications) into a weekly job. This way I can keep a history of database growth and use it for charting expected growth etc.

    if exists (select * from dbo.sysobjects where id = object_id(N'[dbo].[DBStats]') and OBJECTPROPERTY(id, N'IsUserTable') = 1)

    drop table [dbo].[DBStats]

    GO

    CREATE TABLE [dbo].[DBStats] (

    [DBName] [varchar] (100) NOT NULL ,

    [CaptureDT] [datetime] NOT NULL ,

    [FileLogicalName] [varchar] (100) NOT NULL ,

    [Filename] [varchar] (200) NULL ,

    [FileMBSize] [int] NULL ,

    [FileGrowth] [varchar] (20) NULL ,

    [FileMBGrowth] [int] NULL ,

    [DriveName] [varchar] (50) NULL ,

    [DriveMBEmpty] [int] NULL ,

    [FileMBUsed] [int] NULL ,

    [FileMBEmpty] [int] NULL ,

    [FilePercentEmpty] [numeric](5, 2) NULL

    ) ON [PRIMARY]

    GO

    ALTER TABLE [dbo].[DBStats] WITH NOCHECK ADD

    CONSTRAINT [PK_DBStats] PRIMARY KEY CLUSTERED

    (

    [DBName],

    [CaptureDT],

    [FileLogicalName]

    ) ON [PRIMARY]

    GO