Level Extreme platform
Subscription
Corporate profile
Products & Services
Support
Legal
Français
Return a scalar value from SQL Server 2000 UDF
Message
From
27/09/2005 09:27:48
Keith Payne
Technical Marketing Solutions
Florida, United States
 
General information
Forum:
ASP.NET
Category:
ADO.NET
Miscellaneous
Thread ID:
01053027
Message ID:
01053392
Views:
6
Pete,

Already answered above.

>Hello All, could someone please help me out here, how do I call the SQL Server 2000 function below using C# and ADO.Net, I've tried treating it like a stored proc but without success
>
>
>
>FUNCTION ResolveToMaster (@cUnknown varchar(10))
>RETURNS varchar(10)
>AS
>begin
>
>
>declare @MasterRef varchar(10)
>
>select @MasterRef = null
>
>
>select  @MasterRef = (Select Distinct MasterRef from Claim where MasterRef =  @cUnknown)
>
>if @MasterRef is null
>begin
>	select  @MasterRef = (Select Distinct MasterRef from  Claim where CustomerRef =  @cUnknown)
>	
>end
>
>if @MasterRef is null
>	begin
>		select  @MasterRef = (Select Distinct MasterRef from Claim where ClaimRef =  @cUnknown)
>		
>	end
>
>
>Return @MasterRef
>end
>
>
>
>
>what I'm trying to achieve here is, to allow a user to enter either of three different numbers and resolve the number to a master reference ( their idea not mine !?? )
Previous
Reply
Map
View

Click here to load this message in the networking platform