Please start any new threads on our new
site at https://forums.sqlteam.com. We've got lots of great SQL Server
experts to answer whatever question you can come up with.
| Author |
Topic |
|
sunsanvin
Master Smack Fu Yak Hacker
1274 Posts |
Posted - 2007-07-23 : 05:07:47
|
| dear folks,please check my function i'm getting error like thisSelect statements included within a function cannot return data to a client.create function getuomid(@uomcode varchar(50))returns varcharas begindeclare @uom_id varchar(50)select uom_id from vuom where uom_code=@uomcodereturn @uom_idendgoVinodEven you learn 1%, Learn it with 100% confidence. |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2007-07-23 : 05:12:44
|
[code]CREATE FUNCTION getuomid(@uomcode varchar(50))RETURNS varchar(50)AS BEGIN DECLARE @uom_id varchar(50) SELECT @uom_id = uom_id FROM vuom WHERE uom_code = @uomcode RETURN @uom_idEND[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-07-23 : 05:13:15
|
| create function getuomid(@uomcode varchar(50))returns varcharas begindeclare @uom_id varchar(50)select @uom_id = uom_id from vuom where uom_code=@uomcodereturn @uom_idendPeter LarssonHelsingborg, Sweden |
 |
|
|
SwePeso
Patron Saint of Lost Yaks
30421 Posts |
Posted - 2007-07-23 : 05:13:31
|
Peter LarssonHelsingborg, Sweden |
 |
|
|
khtan
In (Som, Ni, Yak)
17689 Posts |
Posted - 2007-07-23 : 05:14:53
|
[code]SELECT COUNT = COUNT + 1[/code] KH[spoiler]Time is always against us[/spoiler] |
 |
|
|
sunsanvin
Master Smack Fu Yak Hacker
1274 Posts |
Posted - 2007-07-23 : 05:40:22
|
| thank you KH and PesoVinodEven you learn 1%, Learn it with 100% confidence. |
 |
|
|
|
|
|