Skip to Main Content

Database Software

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

Import GeoTIFF to GEORASTER, permission

2682881May 29 2014 — edited May 29 2014

Hello,

I'm trying to import a GeoTIFF into Oracle Spatial. But it seems that I have rights problem.

What I did :

  • I created the Georaster table (city_images, like in the Oracle documentation)
  • I created the raster data table (city_images_rdt)
  • I granted the permissions for my user (MDSYS) :

call dbms_java.grant_permission('MDSYS','SYS:java.io.FilePermission', 'C:\test.tif', 'read' );

  • I created the procedure :

create or replace

procedure GEORASTERPROC(imgpath in varchar2) as

geor SDO_GEORASTER;

BEGIN

INSERT INTO city_images values( 1, 'TIFF', sdo_geor.init('city_images_rdt') );

SELECT image INTO geor FROM city_images WHERE image_id = 1 FOR UPDATE;

sdo_geor.importFrom(geor, NULL, 'TIFF', 'file', "C:\test.tif");

UPDATE city_images SET image = geor WHERE image_id = 1;

COMMIT;

END;


And I have the following error :

ORA-13464: error loading GeoRaster data : the Permission (java.io.FilePermission C:\test.tif read) has not been granted to MDSYS. The PL/SQL to grant this is dbms_java.grant_permission( 'MDSYS', 'SYS:java.io.FilePermission', 'C:\test.tif', 'read' )

ORA-06512: at "MDSYS.MD", ligne 1723

ORA-06512: at "MDSYS.MDERR", ligne 17

ORA-06512: at "MDSYS.SDO_GEOR", ligne 5539

ORA-06512: at line 12

13464. 00000 -  "error loading GeoRaster data: %s"

*Cause:    An internal error occurred while loading GeoRaster data into the database.

*Action:   Check the error message for details.

Thanks for your answers

Best regards

Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Jun 26 2014
Added on May 29 2014
2 comments
1,701 views