shshderen 2011-09-04 17:57:55 3752次浏览 1条回复 0 0 0

用yii关联 如何实现

select t.id,b.s1,b.s2  from tbl_t t LEFT OUTER JOIN (select tid,sum(s1) as s1,sum(s2) as s2 from tbl_b group by tid) b on(t.id=b.tid)
您需要登录后才可以回复。登录 | 立即注册