Available DB Space

  • I need to put something in place to act as an early warning for databases reaching maximum size. I don't want uncontrolled growth so I set things to a particular size and turned off Auto Grow. I can manually get the information I need from sp_spaceused, but I want to run a query that will return the same data into a rowset.

    Is there a way to select from a stored procedure?

    Tim

  • try this:

    select *

    from master.sys.databases D

    left Join master.sys.master_files F on F.database_id = D.Database_id

    [font="Times New Roman"]-- RBarryYoung[/font], [font="Times New Roman"] (302)375-0451[/font] blog: MovingSQL.com, Twitter: @RBarryYoung[font="Arial Black"]
    Proactive Performance Solutions, Inc.
    [/font]
    [font="Verdana"] "Performance is our middle name."[/font]

Viewing 2 posts - 1 through 1 (of 1 total)

You must be logged in to reply to this topic. Login to reply