View Complete Post
I get a message - "Function without an 'As' clause" for HMAC_MD5 and "Variable declaration without an 'As' clause" for Key and Value. But the code works. But the messages still exists. Is there a way to fix this to avoid the messages?
Function HMAC_MD5(ByVal Key, ByVal Value)
I am working with ASP.NET with Visual Basic. I have a field called "Amount" that contains numeric information (15000.000). When I display this information in a field called "Sales", I want it to appear as 15,000.00
What is the name of the function that I should use?
anybody help me, i wanna create function using table name parameter.
this is my function code
ALTER function [dbo].[CreateRecID]( @TableName varchar(100))
declare @RecID bigint
declare @Sql varchar(2000)
set @Sql = (select case when max(RecID) is null then 0 else max(RecID) + 1 end as RecID from @TableName)
when i run this code
i got error "Must declare the table variable "@TableName".
I have already declare a @TableName Parameter.
can you show me the way to solve my problem?
Thanks so much
I am trying to call a function in SQL Server 2005 from Access 2003. It works fine with the constant value, but fails with a variable of the same value. This works:
strSQL = "SELECT * FROM functionName (constantValue)"
rs.Open strSQL, cn
when I use variable in the parameter, I get error. I have tried creating parameter objects in Access, but couldn't execute it and don't know if this is a way to go anyway.
Would appreciate for any help or suggestion.
My question is whether I can feed a table variable to my table-valued function in SQL 2005 SP3 standard edition?
If no, can I feed a XML type to the function? I guess, probably I can feed a XML. Yet, for this case I am afraid , in the function, the XML-parsing may be costly if I stuff over 10K uniqueIdentifier data into this XML variable.
Any good idea from you ?