Database Reference
In-Depth Information
Checking
SSAS
object
sizes
programmatically
Most SSAS databases contain data for a finite time span instead of perpetually accu-
mulating data. After a while, data becomes stale and irrelevant for frequent analysis
and should be either purged or migrated to a historical database. Since the volumes
of the data we work with tend to grow quickly, we need to have a way of quickly check-
ing the available disk space as well as the size of each object.
How to do it...
Microsoft supplies a couple of handy commands you could execute directly from the
SSMS MDX query window to obtain the free disk space amount on the data drive.
1. You can execute SYSTEMGETLOGICALDrives within SSMS or from the
ASCMD utility. The command doesn't take any parameters, as shown in the
following code snippet:
SYSTEMGETLOGICALDRIVES
The following table shows the result:
Drive
Free Space
E:
5309
The output of the SYSTEMGETLOGICALDRIVES command depends on the
AllowedBrowsingFolders property value. Had I included C:\ in the Al-
lowedBrowsingFolders property value, the output would include both C
and E drives.
Search WWH ::




Custom Search