- Get ASCMD for right version
-Create a file with XMLA / MDX Command and give extension as xmla/mdx
-Create one batch file with command text as "d:\asjob\ascmd -S karan2k8-64\sql2005 -i d:\asjob\backup.xmla"
In my instance- ASCMD is located in D Drive ASJob folder that’s why I had given it in Path, AS Xmla file is located located in same folder.
In order to remove confusion at the time of ASCMD execution better to keep batch files, ascmd.exe and xmla / mdx files in same folder.
In this command-
-S is AS Server Name
-I is Input file with MDX / XMLA Command
-Open SSIS, Create New package and Add Process Execute Task
-Go to the properties of Process Execute Task and provide the location of batch file as Executable
-Ensure that files are located in one directory and right paths had been specified else you will get the error message.
-Keep all Files (bat,ascmd and AS Command ) in one directory
Attached are copies of ascmd for SQL 2005 and SQL 2008