Select a.部门,
a.最近登陆时间,
b.prev_exec_start 访问时间,
b.username 访问用户,
b.姓名
From zlClients A,
(Select a.Prev_Exec_Start, a.Username, Terminal, c.姓名
From sys.gv_$session A, 上机人员表 B, 人员表 C
Where a.Username = b.用户名
And b.人员id = c.Id
And a.Program = 'ZLHIS+.exe') b
where a.工作站 = b.TERMINAL(+)
and b.username is not null