select b.* from ( select kh,xm,cph,klx,max(jcrq) as jcrq,sfgq from jcbb where ccrq is null group by kh,xm,cph,klx,sfgq ) a inner join jcbb b on a.kh=b.kh and a.jcrq=b.jcrq order by b.jcrq -- try 接分
select jcbb.kh,jcbb.xm,jcbb.cph,jcbb.klx,jcbb.jcrq,jcbb.sfgq,jcbb.images from jcbb,
(select B.kh,jcrq =min(B.jcrq) FROM jcbb B groupby B.kh)A
where jcbb.kh = A.kh AND jcbb.jcrq = A.jcrq
select*from jcbb a
wherenotexists(select1from jcbb b
where a.kh=b.kh and a.jcrq<b.jcrq)
select*from jcbb a
where a.jcrq in (selectmax(b.jcrq) from jcbb b where a.kh=b.kh)
select*from jcbb a
where a.jcrq in (selecttop1 b.jcrq from jcbb b where a.kh=b.kh
orderby b.jcrq desc)