MySQL

쿼리

홍이순이아빠 2016. 8. 12. 17:49

// UPDATE JOIN 샘플

update tbl_board as a inner join (select bno, count(rno) as replyCnt from tbl_reply group by bno) as b

on a.bno = b.bno

set a.replycnt = b.replyCnt;