![]() | |
![]() |
| | Thread Tools | Display Modes |
#1
| |||
| |||
|
#2
| |||
| |||
|
|
I am trying to deploy my assembly. I have followed the example that Mosha has posted at http://sqljunkies.com/WebLog/mosha/a...x_ranking.aspx and create a simple test function. using System; using System.Collections.Generic; using System.Text; using Microsoft.AnalysisServices.AdomdServer; namespace SqlTestAssembly { public class MyClass { public static int myValue() { return 5; } } } Next I deployed the compiled dll to the Server and the Database using the Register Assembly Pages. Next I add my dll to the GAC. When I run "select SqlTestAssembly.MyClass.myValue() on 0 from [Adventure Works]" I get the error Executing the query ... Query (1, 9) The '[SqlTestAssembly].[MyClass].[myValue]' function does not exist. Execution complete Any Ideas? |
#3
| |||
| |||
|
|
prefix the function call: select [Name of the assembly].SqlTestAssembly.MyClass.myValue() on 0 from [Adventure Works] [Name of the assembly] is the name assigned to the assembly into AS (when you insert a new assembly, you have to provide a name.) So, if you publish 2 times the same assembly using 2 different names, you can access each one separatly: select [Name of the assembly1].SqlTestAssembly.MyClass.myValue() on 0 from [Adventure Works] select [Name of the assembly2].SqlTestAssembly.MyClass.myValue() on 0 from [Adventure Works] "MikeP" <MPeverill (AT) gmail (DOT) com> wrote in message news:1152814146.532654.73930 (AT) i42g2000cwa (DOT) googlegroups.com... I am trying to deploy my assembly. I have followed the example that Mosha has posted at http://sqljunkies.com/WebLog/mosha/a...x_ranking.aspx and create a simple test function. using System; using System.Collections.Generic; using System.Text; using Microsoft.AnalysisServices.AdomdServer; namespace SqlTestAssembly { public class MyClass { public static int myValue() { return 5; } } } Next I deployed the compiled dll to the Server and the Database using the Register Assembly Pages. Next I add my dll to the GAC. When I run "select SqlTestAssembly.MyClass.myValue() on 0 from [Adventure Works]" I get the error |
![]() |
| Thread Tools | |
| Display Modes | |
| |