spool all_oco_pref_usage.rslt 

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

break on "POLICY" on "PREFERENCE" on "Name";

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

select  substr(A.POL_NAME,1,20)			"POLICY",
        substr(A.PRE_NAME,1,20)			"PREFERENCE",
        substr(B.ATT_NAME,1,20)              	"Name",
        substr(B.ATT_VALUE,1,20)              	"Value",
        substr(B.ATT_DESC,1,10)              	"Description"
from ctxsys.ctx_preference_usage A,
     ctxsys.ctx_preference_attributes B
where A.PRE_OWNER = B.PRE_OWNER 
and A.PRE_NAME = B.PRE_NAME
and ATT_NAME != 'STOP_WORD'
and A.POL_NAME not like 'TEMPLA%'
order by 1 asc, 2 asc, 3 asc;

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









