UPDATE AllNews
SET ArticleSource = pp.[NewsText]
FROM AllNews AS an
INNER JOIN ( select t1.Id,
stuff((SELECT distinct '.' + t2.[Text]
FROM NewsPhotos t2
where t2.NewsId = t1.Id
FOR XML PATH('')),1,1,'') as [NewsText]
from AllNews t1
group by t1.Id) as pp
ON pp.Id = an.Id