[Gdal-dev] ogrinfo and oracle spatial

Mateusz Loskot mateusz at loskot.net
Fri Jun 9 06:51:41 EDT 2006


Daniel Goetz wrote:
> Thank you Mateusz for your help.
> 
> Unfortunatelly the command: "ogrinfo OCI:gds_brwk2004_umn/umn at gds1prod"
> brought back the following (this tiem I used the ogrinfo
> integrated in ms4w:
> 
> FAILURE:
> Unable to open datasource 'OCI:gds_brwk2004_umn/umn at gds1prod' with the following drivers.
> 
> -> ESRI Shapefile
> ->MapInfo File
> ->UK .NTF
> ->SDTS
> ->TIGER
> ->S57
> ->DGN
> ->VRT
> ->AVCBin
> ->REC
> ->Memory
> ->CSV
> ->GML
> ->ODBC
> ->PGeo
> ->PostgreSQL
> ->MySQL


As you can see, list of supported drivers of your OGR does not include
OCI for Oracle Spatial.
This is the problem.


> Subsequent I watched out fo the supported formats by commanding:
> "ogrinfo --formats"
> 
> the result was:
> 
> Loaded OGR Format Drivers:
> ->"ESRI Shapefiel" 
> ->"MapInfo File"
> ->"UK .NTF"
> ->"SDTS"
> ->"S57"
> ->"DGN"
> ->"VRT"
> ->"AVCBin"
> ->"REC"
> ->"Memory"
> ->"CSV"
> ->"GML"
> ->"ODBC"
> ->"PGeo"
> ->"PostgreSQL"
> ->"MySQL"


Yes, this is the same list as above you got with the error message.


> Can you please tell me whether the needed driver for oracle
> spatial is supported in my OGR. Can you tell me what I further
> sould do.


AFAIK,
you have to build GDAL yourself with OCI driver included in the OGR.
I'm writing 'AFAIK', because I don't know if there is any FWTools or
MS4W or any other package that provides OGR built with OCI support.

I assume you're using Windows, you can turn on OCI support by
editing nmake.opt file.
Find OCI word and you will see appropriate options/paths to enable this
driver (look for "Add ORACLE support" section).

On Unix, you can use --with-oci option for ./configure script.

BTW, I've never used OCI myself, so I'm giving you some suggestions I
base on  my knowledge, but not experience.

Cheers
-- 
Mateusz Loskot
http://mateusz.loskot.net



More information about the Gdal-dev mailing list