MINI MINI MANI MO

Path : /opt/oracle/product/18c/dbhomeXE/md/admin/
File Upload :
Current File : //opt/oracle/product/18c/dbhomeXE/md/admin/opgrelod.sql

Rem
Rem $Header: sdo/admin/pg/opgrelod.sql /main/6 2017/09/29 09:00:20 alwu Exp $
Rem
Rem opgrelod.sql
Rem
Rem Copyright (c) 2013, 2017, Oracle and/or its affiliates. 
Rem All rights reserved.
Rem
Rem    NAME
Rem      opgrelod.sql - <one-line expansion of the name>
Rem
Rem    DESCRIPTION
Rem      <short description of component this file declares/defines>
Rem
Rem    NOTES
Rem      <other useful comments, qualifications, etc.>
Rem
Rem    MODIFIED   (MM/DD/YY)
Rem    alwu        09/28/17 - shorten several API names
Rem    alwu        02/18/16 - add opg_auto_lexer
Rem    alwu        12/14/15 - take out OJVM dependency
Rem    alwu        12/03/15 - add SQL FILE metadata
Rem    alwu        07/23/15 - fix bug 21226251
Rem    alwu        01/21/14 - add mdsys to package names
Rem    alwu        01/08/14 - add graph op package
Rem    alwu        11/18/13 - add a helper function for elapsed time
Rem    alwu        11/18/13 - update
Rem    alwu        11/18/13 - hook up utility
Rem    alwu        11/18/13 - add ranking related packages
Rem    alwu        11/15/13 - start
Rem    alwu        11/15/13 - Created
Rem
Rem    BEGIN SQL_FILE_METADATA 
Rem    SQL_SOURCE_FILE: sdo/admin/pg/opgrelod.sql 
Rem    SQL_SHIPPED_FILE: md/admin/opgrelod.sql 
Rem    SQL_PHASE: OPGRELOD
rem    SQL_STARTUP_MODE: NORMAL 
Rem    SQL_IGNORABLE_ERRORS: NONE 
Rem    SQL_CALLING_FILE: sdo/admin/pg/catopg.sql
Rem    END SQL_FILE_METADATA

SET ECHO ON
SET FEEDBACK 1
SET NUMWIDTH 10
SET LINESIZE 80
SET TRIMSPOOL ON
SET TAB OFF
SET PAGESIZE 100

set echo off;

Rem ********************************************************************
Rem #16473696: Indicate Oracle-Supplied object
@@?/rdbms/admin/sqlsessstart.sql
Rem ********************************************************************

alter session set current_schema=MDSYS;

--  create or replace and compile 
--    java source named "oracle.spatial.pg.Timer"
--  as   
--    package oracle.spatial.pg;
--    public class Timer 
--    {
--      public static long currentTimeMillis() 
--      {
--        return System.currentTimeMillis();
--      }
--    }
--  /
--
-- 
--  create or replace function mdsys.currentTimeMillis return number
--  as
--    language java
--    name 'oracle.spatial.pg.Timer.currentTimeMillis() return long';
--  /
--
--  grant execute on mdsys.currentTimeMillis to public;
 
grant execute on dbms_flashback to MDSYS;

@@opgctxh.sql

CREATE OR REPLACE CONTEXT OPG_CTX using MDSYS.OPG_CTX accessed globally;

CREATE OR REPLACE CONTEXT OPG_CTX_SESSION using MDSYS.OPG_CTX_SESSION;

@@opgctxb.plb 

@@opglogh.sql
@@opgapih.sql
@@opgutlh.sql
@@opgpathh.sql
@@opgrankh.sql
@@opgmetricsh.sql
@@opggraphoph.sql

@@opglogb.plb
@@opgapib.plb
@@opgutlb.plb
@@opgpathb.plb
@@opgrankb.plb
@@opgmetricsb.plb
@@opggraphopb.plb

-- Add an auto lexer
begin
  execute immediate 'begin ctx_ddl.create_preference(''MDSYS.OPG_AUTO_LEXER'', ''AUTO_LEXER''); end;';
exception
  when others then 
    null;
end;
/

Rem ********************************************************************
Rem #16473696: Indicate Oracle-Supplied object
@@?/rdbms/admin/sqlsessend.sql
Rem ********************************************************************


OHA YOOOO