Query SSAS Server Properties

  • Is there a query that I can run against Anaylsis Services that will return the backup folder server property setting? I have an SSIS job I want to run on numerous SQL/AS servers that need to write and read a CSV file. Since this location differs on each server, I'd like to dynamically be able to set this connection string in the package.

  • Yes, there is. Here's the PowerShell and AMO (Analysis Management Objects) way. 😉

    [System.Reflection.Assembly]::LoadWithPartialName("Microsoft.AnalysisServices") | Out-Null;

    [Microsoft.AnalysisServices.Server] $srv = New-Object Microsoft.AnalysisServices.Server;

    [string]$ServerName = "Server\Instance";

    $srv.Connect($ServerName);

    $BackupDestination = $srv.ServerProperties.Item("BackupDir").Value;

    $BackupDestination;

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

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