The MDSYS.SDO_GEOR_UTL package contains subprograms (functions and procedures) for utility operations related to GeoRaster. This chapter presents reference information, with one or more examples, for each subprogram.
SDO_GEOR_UTL.createDMLTrigger(
tableName VARCHAR2,
columnName VARCHAR2);
Creates the required standard GeoRaster data manipulation language (DML) trigger on a GeoRaster column in a GeoRaster table, so that the appropriate operations are performed when its associated trigger is fired.
Name of a GeoRaster table (the table containing rows with at least one GeoRaster object column).
Name of a column of type SDO_GEORASTER in the GeoRaster table.
To maintain the referential integrity of GeoRaster data structures, you should always use this procedure to create the standard GeoRaster DML trigger on each GeoRaster table and GeoRaster column combination before you perform any DML operations on the table. For example, if the GeoRaster table contains two GeoRaster columns, call this procedure twice, specifying the appropriate table name and column name for each call.
For more information about the standard GeoRaster DML trigger, including the operations that it performs, see Section 3.1.1.
The following example creates the standard GeoRaster DML trigger for a table named XYZ_GEOR_TAB containing a GeoRaster column named GEOR_COL.
EXECUTE sdo_geor_utl.createDMLTrigger('XYZ_GEOR_TAB', 'GEOR_COL');
SDO_GEOR_UTL.makeRDTNamesUnique;
Renames some existing raster data tables that do not have unique names so that all raster data table names are unique within the database, and updates the GeoRaster system data and all affected GeoRaster objects to reflect the new names.
None.
If one or more raster data tables have the same name (under different schemas), you can use this procedure or the SDO_GEOR_UTL.renameRDT procedure, or both, to eliminate the duplication.
Run this procedure when you are connected to the database with the DBA role.
The following example automatically renames some existing raster data tables that do not have unique names so that all raster data table names are unique within the database, and it updates the GeoRaster system data and all affected GeoRaster objects to reflect the new names.
EXECUTE sdo_geor_utl.makeRDTNamesUnique;
SDO_GEOR_UTL.renameRDT(
oldRDTs VARCHAR2,
newRDTs VARCHAR2 DEFAULT NULL);
Renames one or more existing raster data tables owned by the current user, and updates the GeoRaster system data and all affected GeoRaster objects to reflect the new names.
Name of the raster data table or tables to be renamed. For multiple tables, use a comma-delimited list.
New names to be assigned to the raster data table or tables that are specified in oldRDTs
. For multiple tables, use a comma-delimited list with an order exactly reflecting the names in oldRDTs
. If this parameter is null, GeoRaster assigns a unique new name to each input raster data table.
If one or more raster data tables owned by different users have the same name, you can use this procedure or the SDO_GEOR_UTL.makeRDTNamesUnique procedure, or both, to eliminate the duplication.
Before using this procedure, you must connect to the database as the owner of the raster data table or tables. You cannot use this procedure to rename a raster data table owned by another user.
If any table in oldRDTs
is not included in the GeoRaster system data, it is ignored.
If any table in newRDTs
conflicts with a name in the GeoRaster system data or with the name of another object owned by the current user, an exception is raised.
The following example renames the raster data tables RDT_1 and RDT_2 to ST_RDT_1 and ST_RDT_2, respectively.
CONNECT scott/tiger; . . . EXECUTE sdo_geor_utl.renameRDT('RDT_1,RDT_2','ST_RDT_1,ST_RDT_2');