34,838
社区成员




declare cur cursor for
select textptr(Col) from T
declare @p binary(16)
open cur
fetch next from cur into @p
while @@fetch_status=0
begin
updatetext T.Col @p null null N'aa'
fetch next from cur into @p
end
close cur
deallocate cur
结合使用:可以看看联机丛书的说明
textvalid()
textptr()
updatetext()
update tablea
set dd=cast(cast(dd as varchar)+'aa' as text)