SQL Server Performance

Processing cube using AMO & vbscript

Discussion in 'SQL Server 2005 Analysis Services' started by ferec, Apr 3, 2008.

  1. ferec New Member

    Hello, I tried to process an OLAP 2005 cube from VBScript. I used the script listed below, everything went fine until the processing step. Is it possible to process cube using AMO with VBScript? If not, then why is it possible to connect with AMO?
    Set amoPT = CreateObject("Microsoft.AnalysisServices.ProcessType")
    Set amoServer = CreateObject("Microsoft.AnalysisServices.Server")
    Set amoDB = amoServer.Databases.item("test1")
    Set amoCube = amoDB.Cubes.item("Pubs")

    amoCube.Process (0)
    Thank in advance,
    Ferenc Lengyel
  2. ranjitjain New Member

    What kind of error do you get.
    There are various other options which you could use as well.
    1>create ssis package and include AS processing task.
    2>create .net script task and then use .net script to process the cube by importing AS libraries, i.e. Microsoft.AnalysisServices.
    3>Create XML batch in script taks and pass it to the AS execute DDL task.
    Finally call this package through job or stored procedure.
  3. ferec New Member

    It returns this error:
    Wrong number of arguments or invalid property assignment: 'amoCube.Process'
    If I try to run Process method without any argument, the error doesn't appear, but doesn't process the cube. I tried this on the level of Measure group or partitions with same results.
    My goal is to use code that is not compiled (so I can change it from anywhere without development tools) - VBScript was perfect for it and I don't need SSIS, no tried to avoid install it. If there is any possibility to replace VBScript with a .NET scripting language, I would be happy.
    thank you.

Share This Page