Wrox Programmer Forums
|
SQL Server 2000 General discussion of Microsoft SQL Server -- for topics that don't fit in one of the more specific SQL Server forums. version 2000 only. There's a new forum for SQL Server 2005.
Welcome to the p2p.wrox.com Forums.

You are currently viewing the SQL Server 2000 section of the Wrox Programmer to Programmer discussions. This is a community of software programmers and website developers including Wrox book authors and readers. New member registration was closed in 2019. New posts were shut off and the site was archived into this static format as of October 1, 2020. If you require technical support for a Wrox book please contact http://hub.wiley.com
 
Old May 24th, 2007, 08:39 AM
Authorized User
 
Join Date: Nov 2006
Posts: 32
Thanks: 0
Thanked 0 Times in 0 Posts
Default How to use Function

Hi

I have created a function. it created successfully. But when i want to use it, then it gives some error message : 'func3' is not a recognized function name.

step 1

create function func3 (@p1 int,@p2 int)
returns int
as
begin
return @p1 * @p2
end

step 2

Select func3(5,6) as result

or

declare @x int
Set @x=func3(5,6)
print @x

Thanks in advance
Kumar Ashish
krashishroa@yahoo.co.in
__________________
Thanks
Kumar Ashish
krashishroa@yahoo.co.in
 
Old May 28th, 2007, 05:04 AM
Friend of Wrox
 
Join Date: Jun 2003
Posts: 2,480
Thanks: 0
Thanked 1 Time in 1 Post
Default

Code:
Select dbo.func3(5,6) as result
You are missing the reference there.

_________________________
- Vijay G
Strive for Perfection





Similar Threads
Thread Thread Starter Forum Replies Last Post
function keyvanjan ASP.NET 2.0 Professional 1 September 19th, 2007 10:22 AM
send variable in function to another function schoolBoy Javascript How-To 6 March 3rd, 2007 09:16 AM
Please help with function fugru Excel VBA 2 January 29th, 2007 04:34 AM
How to call javascript function from VB function vinod_yadav1919 VB How-To 0 February 13th, 2006 06:03 AM
retreive function/Line from macro or function? MikoMax J2EE 0 April 1st, 2004 04:42 AM





Powered by vBulletin®
Copyright ©2000 - 2020, Jelsoft Enterprises Ltd.
Copyright (c) 2020 John Wiley & Sons, Inc.