标签:io ar strong sp on cti bs as sql
create function fun_A() #标题函数、create function fun_name() returns output_type as begin return value end;
returns int
as
begin
return 1;
end
go
create function fun_B() #多语句用户定义函数、create function fun_name() returns @value table(colum_list) as begin return ; end
returns @tb table(ID int ,Name nvarchar(8))
as
begin
insert into @tb(ID,Name) values(1,‘111‘),(2,‘222‘);
return;
end
go
create function fun_C() #内联用户定义函数、create function fun_name() returns table as return select......;
returns table
as
return select 1 as A,2 as B,3 as C;
go
标签:io ar strong sp on cti bs as sql
原文地址:http://www.cnblogs.com/JiangLe/p/4052674.html