单字段去重 distinct 返回其他多个字段

select a.*,
group_concat(distinct b.attribute_name)
from
sign_contract_info a
left join
sign_temp_attribute b
on
a.temp_attribute_id = b.id_
left join
sign_temp_project c
on
a.temp_project_id = c.id_
where
a.enable_=1
AND a.company_info_id = 32
group by b.attribute_name

参考

https://www.cnblogs.com/longsanshi/p/7680860.html

上一篇:WebConfig 自定义节点configSections配置信息


下一篇:Codeforces243A The Brand New Function