|
|
|||||||||
|
|||||||||
|
|||||||||
| |
||
| ||||||||||||||||||||||||||
![]() |
|
|
«
Previous Thread
|
Next Thread
»
|
Thread Tools | Search this Thread | Rate Thread | Display Modes |
|
#1
|
|||
|
|||
|
SQL Server 2005 - Calling User defined functions
I have created a user defined function that takes a string as input.
EG: Create function func_new(@str varchar(20)) returns varchar(20) begin ...... //whatever code ..... return @str1 end @str is a table column(col1) How do I call this function so that all columns in the table get manipulated by the function?? Do i have to write a stored proc to call this function or something else has to be done? |
|
#2
|
||||
|
||||
|
Calling User defined functions
Have a read of the following article which will help you create and use your function. Read Me
__________________
Hope this advise helps. ![]() If so please show your appreciation by adding reputation points (click gauge image on top right of this post and score).
|
|
#3
|
|||
|
|||
|
You can apply a function to every row of a recordset by using the APPLY statement.
http://msdn.microsoft.com/en-us/library/ms175156.aspx However, your function must be a table valued function, not a scalar function. |
![]() |
| Viewing: ASP Free Forums > Database > Microsoft SQL Server > SQL Server 2005 - Calling User defined functions |
| Thread Tools | Search this Thread |
| Display Modes | Rate This Thread |
|
|
|
|
|