spool all_oco_servers.rslt 

set linesize 130;
set pagesize 1000;
set long 50;
set echo on;

break on "Machine" on "Instance" on "Name";

/* ****************************************************** */
/*                                                        */
/*  - will show all the servers for a given database     */
/*     - for use with CONTEXT CARTRIDGES                  */
/*                                                        */
/* ****************************************************** */

select  substr(SER_MACHINE,1,20)						"Machine",
	  substr(SER_DB_INSTANCE,1,8)					"Instance",
        substr(SER_NAME, 1,16)              				"Name",
        substr(SER_STATUS,1,8)						"Status",
    	  substr(to_char(SER_STARTED_AT, 'YYYY-MON-DD HH:MI:SS am'), 1,25)  "Started:",
   	  substr(to_char(SER_IDLE_TIME, '999,999'), 1,9)  		"Idle(sec)"
from ctxsys.ctx_all_servers 
order by 1 asc, 2 asc, 3 asc;


set echo off;
spool off;
set long 80;
commit;









