sql 怎样截取指定位置的中英文混合体 例如 截取‘我是中国人0001’ 的8 至 14字节

[复制链接]
查看11 | 回复1 | 2013-5-22 18:49:53 | 显示全部楼层 |阅读模式
create table #temp( testvarchar(20) );INSERT INTO #temp VALUES('我是中国人0001');goSELECTConvert(char(8), test) AS [0to8],Convert(char(14), test) AS [0to14], RIGHT(Convert(char(14), test), LEN(Convert(char(14), test)) - LEN(Convert(char(8), test))) AS [8to14]FROM #tempGO0to8
0to14
8to14-------- -------------- -...
回复

使用道具 举报

您需要登录后才可以回帖 登录 | 立即注册

本版积分规则

主题

0

回帖

4882万

积分

论坛元老

Rank: 8Rank: 8

积分
48824836
热门排行