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.

 All Forums
 SQL Server 2012 Forums
 Transact-SQL (2012)
 function list and return type

Author  Topic 

chiragvm
Yak Posting Veteran

65 Posts

Posted - 2014-06-09 : 03:05:34
Hello to all
how can i get all scalar function list with return type from query as below

fn_abc varchar
fn_xyz int
fn_def bit

-------------
Chirag
India
Sr.Software Engineer

MuralikrishnaVeera
Posting Yak Master

129 Posts

Posted - 2014-06-09 : 05:48:14
I gave kiran try

SELECT y.name AS 'FunctionName'
,ISNULL(x.DATA_TYPE,'Table')AS 'ReturnType'
FROM (SELECT name FROM sys.objects WHERE type IN ('FN','TF','IF')
)y
LEFT JOIN (SELECT P.SPECIFIC_NAME
,P.DATA_TYPE
FROM INFORMATION_SCHEMA.PARAMETERS P WHERE p.PARAMETER_MODE = 'OUT'
)x
ON y.name = x.SPECIFIC_NAME


---------------
Murali Krishna

You live only once ..If you do it right once is enough.......
Go to Top of Page

chiragvm
Yak Posting Veteran

65 Posts

Posted - 2014-06-09 : 08:38:51
Hello Murali Krishna

thanks a lot for your query , it's work

-------------
Chirag
India
Sr.Software Engineer
Go to Top of Page
   

- Advertisement -