แก้แล้วเป็น แต่ยังไม่ได้เรื่องเวลาครับ
select er.vstdate,ep.begin_time,v.hn,concat(p.pname,p.fname,' ',p.lname) as name,er.er_list,er.er_doctor,d.name AS doctor from er_regist_oper ep
left outer join er_regist er on er.vn=ep.vn
left outer join vn_stat v on v.vn=ep.vn
left outer join patient p on p.hn=v.hn
left outer join doctor d on d.code=er.er_doctor
where ep.begin_time between "16:30:00" and "23:59:59" and er.er_doctor NOT IN ('06','114','124') and er.vstdate between '2010-10-01' and '2010-10-10'
order by er.vstdate desc