select a.会员名,a.性别,a.年龄,b.最近登陆时间 from AA as a left join BB as b on a.会员名=b.会员名 order by b.最近登陆时间
------解决方案--------------------
------解决方案-------------------- select [user].*,[login].8 from [user] where username in (select top 1 * from [login] order by logintime desc)
------解决方案--------------------