Select * from cs_bbs_data where (code='bbslaw' and ccode='kncvc') or (code='bbslaw' and sharing='Y' ) order by notice DESC, reg_date DESC LIMIT 100, 10