SQL 取字符串列表
时间:2011-06-10 来源:amylis
declare @s varchar(100)
set @s=N'D3中国gi'
SELECT datalength(CH),LEN(CH),CH,长度
FROM (
select substring(@s,number,1) as ch,LEN(substring(@s,number,1))as '长度'
from master..spt_values
where type='p' and number between 1 and len(@s)
) A
相关阅读 更多 +