Results 1 to 4 of 4

Thread: Database Size

  1. #1
    Join Date
    Nov 2003
    Posts
    68

    Unanswered: Database Size

    I want how can i do to do capacity planning in sqlserver 2000.
    Do you make scripts (vbs) who query the sysfiles tables and transfer the answer in excel ?
    Please help me.
    Phil

  2. #2
    Join Date
    Nov 2003
    Posts
    94
    select cast(sum(m.[size]) * 8 as nvarchar)+N'KB' AS DB_SIZE, cast(sum(l.[size]) * 8 as varchar)+N'KB' AS LOG_SIZE
    from dbo.[sysfiles] m, dbo.[sysfiles] l
    where m.[groupid] != 0
    and l.[groupid] = 0

  3. #3
    Join Date
    Nov 2003
    Posts
    68

    other servers

    Thanks for your answer, can i query other database server with this query ?

  4. #4
    Join Date
    Nov 2003
    Posts
    94
    [servername].[database].[dbo].[sysfiles]

    where the server and database have been linked to the SQL Server you are running the query from

Posting Permissions

  • You may not post new threads
  • You may not post replies
  • You may not post attachments
  • You may not edit your posts
  •