| 
 Posted by R.A.M. on 07/12/06 07:00 
I have one more question - concernign functions. 
I've written function: 
 
        [SqlFunction(Name="GetCurrentDateText")] 
        public static SqlString GetCurrentDateText() 
        { 
            DateTime dt = new DateTime(); 
            return dt.ToString(); 
        } 
 
And I have tried to create a function: 
 
CREATE FUNCTION GetCurrentDateText RETURNS nvarchar(MAX) AS EXTERNAL 
NAME DemoSQLServer.DemoGetCurrentDateText 
 
(according to Books Online) But I recive an error: 
 
Incorrect syntax near 'RETURNS'. 
 
I cannot guess what is wrong. Could you help me please? 
Thank you! 
/RAM/
 
[Back to original message] 
 |