sqlserver:
SELECT
*,
( SELECT Hospitalproperty2 + ‘ ‘ FROM testtable WHERE Hospitalproperty = ‘zhangs‘ FOR XML path ( ‘‘ ) )
FROM
testtable
MySQL:
select *,(select GROUP_CONCAT(b.Hospitalproperty2)from testtable b) from testtable;
标签:spi zha div sel nbsp mysql class 拼接 cat
sqlserver:
SELECT
*,
( SELECT Hospitalproperty2 + ‘ ‘ FROM testtable WHERE Hospitalproperty = ‘zhangs‘ FOR XML path ( ‘‘ ) )
FROM
testtable
MySQL:
select *,(select GROUP_CONCAT(b.Hospitalproperty2)from testtable b) from testtable;
标签:spi zha div sel nbsp mysql class 拼接 cat
原文地址:https://www.cnblogs.com/wangpeng00700/p/8422523.html