-------------------------------
declare @otxt varchar(1000)
set @otxt = 'ExistingText'
declare curs cursor local fast_forward
for
select
id,
textptr(TargetField),
charindex(@otxt, TargetField)-1
from
TargetTable
where
TargetField
like
'%' + @otxt +'%'
----------------------------------------