56,679
社区成员
发帖
与我相关
我的任务
分享
//你要把user_log表中user_id全部取出来,直接group by user_id就行了,为什么还要加上时间
//或者distinct(user_id)
//然后关联表查询,不知道是不是你想要的
select a.user_name,a.regist_Time,a.contact_name,a.company_phone,a.company_name from front_user a,
(select user_id from user_log where 1=1 and apply_time > '$start_time' and apply_time < '$end_time' group by user_id) ss
where a.user_id = ss.user_id