How do you check free space or space used within an MDF? The "Percent Log Used" performance condition alert doesn't check MDF files. The sp_spaceused is close, but combines all files, and sp_helpfile shows current file sizes and growth specs, but not free/used.

How do you programatically get the same values shown by ShrinkFile when in Management Studio?

Thanks - D

FYI to those scratching your head on this... I found a solution using the fileproperty function. Thanks for looking.
- D

Be a part of the DaniWeb community

We're a friendly, industry-focused community of developers, IT pros, digital marketers, and technology enthusiasts meeting, networking, learning, and sharing knowledge.