![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
Hi, In Aanalysis server 2005,we can use AMO classes to manager database,cube,dimension etc.But I cann't find how to add named set and caculated member by amo.I read the help,find MdxScript class can do it. Do anyone know how to add named set and caculated member by MdxScript,thanks. |
#3
| |||
| |||
|
|
The MdxScript class contains a collection of Command objects; in a Command you can put an MDX statement to create a named set or a calculated member (in the Text property). Also, you can try this: - use the cube editor from "SQL Server Business Intelligence Development Studio" to create named sets or calculated members (in the "Calculations" tab) - save the cube and view the XML file (right click on the cube item and use "View Code") - in the XML look for the <MdxScript> element in which you will see the Command> and the <Text> property for sample MDX code to put in AMO - please note that the XML elements have direct correspondence in the AMO classes and properties (for example the <MdxScript> element containing the Commands> element in which there is a <Command> means in AMO: the MdxScript object with Commands property containing Command objects) - you can use this "View Code" option to see how to setup other things in AMO as the editors are doing Adrian Dumitrascu. "msnews.microsoft.com" wrote: Hi, In Aanalysis server 2005,we can use AMO classes to manager database,cube,dimension etc.But I cann't find how to add named set and caculated member by amo.I read the help,find MdxScript class can do it. Do anyone know how to add named set and caculated member by MdxScript,thanks. |
#4
| |||||
| |||||
|
|
1.I check sample database "Adventure Works DW" by BI Studio.In the cube's caculate tab,I found MdxScript has only one command which hold many named set and caculated member,and command object hasn't any property and function to manager it.It is only Text property to get all the named set and caculated member. can I add a named set in one command object then command text is the named set's Mdx Command. |
|
2.What's CalculationProperty? must I set the CalculationProperty when i add named set and caculated member? |
|
How to get added named set 's command by CalculationProperty's CalculationReference property? |
, you can create an associated CalculationProperty with|
3.What's the best solution in Cube's Caculation define? Cube has only one MdxScript, and every Command hold only one caculation difine? |
|
Thanks Adrian's reply I try it,and find somthing understand. 1.I check sample database "Adventure Works DW" by BI Studio.In the cube's caculate tab,I found MdxScript has only one command which hold many named set and caculated member,and command object hasn't any property and function to manager it.It is only Text property to get all the named set and caculated member. can I add a named set in one command object then command text is the named set's Mdx Command. 2.What's CalculationProperty? must I set the CalculationProperty when i add named set and caculated member? How to get added named set 's command by CalculationProperty's CalculationReference property? 3.What's the best solution in Cube's Caculation define? Cube has only one MdxScript, and every Command hold only one caculation difine? Thanks again! "Adrian Dumitrascu" <Adrian Dumitrascu (AT) discussions (DOT) microsoft.com news:20D32B9B-92B9-4106-8726-63FCD5C4144C (AT) microsoft (DOT) com... The MdxScript class contains a collection of Command objects; in a Command you can put an MDX statement to create a named set or a calculated member (in the Text property). Also, you can try this: - use the cube editor from "SQL Server Business Intelligence Development Studio" to create named sets or calculated members (in the "Calculations" tab) - save the cube and view the XML file (right click on the cube item and use "View Code") - in the XML look for the <MdxScript> element in which you will see the Command> and the <Text> property for sample MDX code to put in AMO - please note that the XML elements have direct correspondence in the AMO classes and properties (for example the <MdxScript> element containing the Commands> element in which there is a <Command> means in AMO: the MdxScript object with Commands property containing Command objects) - you can use this "View Code" option to see how to setup other things in AMO as the editors are doing Adrian Dumitrascu. "msnews.microsoft.com" wrote: Hi, In Aanalysis server 2005,we can use AMO classes to manager database,cube,dimension etc.But I cann't find how to add named set and caculated member by amo.I read the help,find MdxScript class can do it. Do anyone know how to add named set and caculated member by MdxScript,thanks. |
![]() |
| Thread Tools | |
| Display Modes | |
| |