去除字符串重复项: declare @str varchar(8000) declare @ret varchar(8000),@return varchar(8000) select @str = 'APR-11,APR12,APR06,APR-11,APR12,APR06' select @str = @str+',' while charindex(',',@str) > 0 begin select @ret = substring(@str,1,charindex(',',@str)-…