select '['+title_a+','+title_b +']' from A for xml path('') SELECT *, (select '['+title_a+','+title_b +']' from A where A.t_id=B.t_id for xml path('') ...
select '['+title_a+','+title_b +']' from A for xml path('')
SELECT *, (select '['+title_a+','+title_b +']' from A where A.t_id=B.t_id for xml path('')) FROM B