摘要:
Create table Tab([Col1] int,[Col2] nvarchar(1))Insert Tab select 1,N'a' union all select 1,N'b' union all select 1,N'c' union all select 2,N'd' union all select 2,N'e' union all select 3,N'f'create function F_Str(@Col1 int) returns nvarchar(100) asbegi 阅读全文
摘要:
create function GetPY(@str varchar(500))returns varchar(500)asbegin declare @cyc int,@length int,@str1 varchar(100),@charcate varbinary(20) set @cyc=1--从第几个字开始取 set @length=len(@str)--输入汉字的长度 set @str1=''--用于存放返回值 while @cyc<=@length begin select @charcate=cast(substring(@... 阅读全文