Good day ,
I would like to use the following script to pull all users logged in that are running jobs from Seagate Info.
Appears that this script should work, but its not. Any help is appreciated. I do / would run it via SQL Plus.
select rpad(username,8)"User",
to_char(logon_time,'MM/DD HH24:MI') "Start Time",
rpad(machine,20) "Info server", status
from v$session
where machine like 'EHS%'
order by 3,2
/*Get count of and list of users on each info server*/
set pagesize 40
break on "Machine" skip 1
compute count of "Ora User" on "Machine"
select rpad(machine,20) "Machine",
rpad(a.username,8) "Ora User",
rpad(to_char(logon_time, 'MM/DD-HH24:MI:SS'),11) "Login Time",
rpad(a.status,1,'_') "S"
from v$session a, v$process b
where a.paddr = b.addr
and machine like 'EHS_PN%'
and a.program like '%Seagate%'
order by 1,2;
Thanks
I would like to use the following script to pull all users logged in that are running jobs from Seagate Info.
Appears that this script should work, but its not. Any help is appreciated. I do / would run it via SQL Plus.
select rpad(username,8)"User",
to_char(logon_time,'MM/DD HH24:MI') "Start Time",
rpad(machine,20) "Info server", status
from v$session
where machine like 'EHS%'
order by 3,2
/*Get count of and list of users on each info server*/
set pagesize 40
break on "Machine" skip 1
compute count of "Ora User" on "Machine"
select rpad(machine,20) "Machine",
rpad(a.username,8) "Ora User",
rpad(to_char(logon_time, 'MM/DD-HH24:MI:SS'),11) "Login Time",
rpad(a.status,1,'_') "S"
from v$session a, v$process b
where a.paddr = b.addr
and machine like 'EHS_PN%'
and a.program like '%Seagate%'
order by 1,2;
Thanks