Here is a simple SQL script to retrieve the free spaces on db files (data, log).
The below script will give you the File size, used space and free space of currently selected database only.
select
name
, filename
, convert(decimal(12,2),round(a.size/128.000,2)) as FileSizeMB
, convert(decimal(12,2),round(fileproperty(a.name,'SpaceUsed')/128.000,2))...
Subscribe to:
Posts (Atom)