 for select meta_id, name
     from texts
     where meta_id > 1000  -- = @meta_id  
+    and type=0
 
 open posCursor
 fetch next from posCursor 

        where meta_id = @meta_id and name = @name                
	update #tmptexts set newtext = replace((select newtext from #tmptexts where meta_id =@meta_id and name = @name),'&aacute;', '')
        where meta_id = @meta_id and name = @name                               


        select @newtext = newtext 


	    SELECT @ptrval = TEXTPTR(text) 
   	    FROM texts
      	    WHERE meta_id = @meta_id and name = @name and type = 0
    
            set @insert_offset = NULL	--A value of NULL appends the new data to the existing data value.
        
