sql 把两条数据拼接为一条数据

select stuff((
select ‘、’+c_nme
from alislb for xml path(”)),1,1,”) as UserName,stuff((
select ‘、’+c_pss
from alislb for xml path(”)),1,1,”) as Num,
stuff((select ‘、’ + RTRIM(c_regstt) from alislb for xml path (”)),1,1,”) as Num

    原文作者:tqyqiutian
    原文地址: https://blog.csdn.net/tqyqiutian/article/details/120363884
    本文转自网络文章,转载此文章仅为分享知识,如有侵权,请联系博主进行删除。
点赞