sql 字符保留汉字处理
declare @s varchar(50)
set @s='abc123汉字abc123汉字'
select PATINDEX('%[吖-座]%',@s) as [index],left(@s,PATINDEX('%[吖-座]%',@s)-1) as s1,stuff(@s,1,PATINDEX('%[吖-座]%',@s)-1,'') as s2
declare @s varchar(50)
set @s='abc123汉字abc123汉字'
select PATINDEX('%[吖-座]%',@s) as [index],left(@s,PATINDEX('%[吖-座]%',@s)-1) as s1,stuff(@s,1,PATINDEX('%[吖-座]%',@s)-1,'') as s2