|
Posted by Erland Sommarskog on 07/17/06 21:38
R.A.M. (r_ahimsa_m@poczta.onet.pl) writes:
> I am learning SQL Server 2005. I have (correctly) written in .NET
> assembly DemoSQLServer with aggregate function AvgNoMinMax in class
> Demo and I have added assembly to database DemoSQLServer. Now I need
> to create aggregate in SQL Server. I tried this way:
>
> CREATE AGGREGATE AvgNoMinMax(@v float) RETURNS float EXTERNAL NAME
> [DemoSQLServer].[DemoSQLServer.Demo].[AvgNoMinMax]
>
> Unfortunately I have error:
>
> Incorrect syntax near '.'.
The thing to do when you get a syntax error is to look up the topic
for the command in question and study the syntax graph in detail to
find out what's wrong.
Yes, I'm telling you to read the manual. You see, you are learning SQL 2005,
and part of that is to learn the tremendous asset that Books Online actually
is. Besides, by doing mistakes and finding what mistake - that is how you
really learn things. You don't learn things by being spoon-fed in
newsgroups.
(That is not to say that asking in newsgroups is a bad idea. Sometimes
it's rather creativity you need help with, and that is not be found in
Books Online.)
--
Erland Sommarskog, SQL Server MVP, esquel@sommarskog.se
Books Online for SQL Server 2005 at
http://www.microsoft.com/technet/prodtechnol/sql/2005/downloads/books.mspx
Books Online for SQL Server 2000 at
http://www.microsoft.com/sql/prodinfo/previousversions/books.mspx
Navigation:
[Reply to this message]
|