CREATE AGGREGATE有问题

时间:2014-05-19 16:14:06

标签: c# sql-server sqlclr

以下是CLR模块的顶部:

namespace CustomAggregates
{
    [System.Serializable]
    [Microsoft.SqlServer.Server.SqlUserDefinedAggregate(
       Microsoft.SqlServer.Server.Format.Native,
       IsInvariantToDuplicates = false,     // receiving the same value again changes the result
       IsInvariantToNulls = false,          // receiving a NULL value changes the result
       IsInvariantToOrder = false,          // the order of the values doesn't affect the result
       IsNullIfEmpty = true,                // if no values are given the result is null
       Name = "Median"                      // name of the aggregate

    )]
    public struct Median
    {
    ...

当我尝试将其添加到SQL Server时,我收到以下消息:

Msg 6556, Level 16, State 1, Line 2
CREATE AGGREGATE failed because it could not find type 'Median' in assembly 'CustomAggregates'.
Msg 6597, Level 16, State 2, Line 2
CREATE AGGREGATE failed.

我错过了什么吗?

0 个答案:

没有答案