[Gdal-dev] OCI-22165 index out-of-range appending PGDB -> Oracle Spatial

Frank Warmerdam warmerdam at pobox.com
Fri Jan 20 22:04:47 EST 2006


On 1/20/06, Dave Fuhry <dfuhry at gmail.com> wrote:
> When appending a personal geodatabase to an Oracle Spatial table with
> the following command:
>
> C:\PGDB-12202005>ogr2ogr -update -append -f OCI OCI:taxmap/taxmap1
> LB011.mdb StreetCenterline -lco INDEX=OFF
>
> I get this error:
>
> ERROR 1: OCI-22165: given index [1048576] must be in the range of [0]
> to [1048575]
>  in OCICollAppend
> ERROR 1: Terminating translation prematurely after failed
>
> Without the " -update -append" it works fine.  I'm getting a little
> lost in the OCI code but it looks like the error occurs in
> ogrocitablelayer.cpp, line 1025 in the OCICollAppend() method call,
> which OCI docs say appends an element to a collection (which would be
> an SDO_ELEM_INFO_ARRAY or SDO_ORDINATE_ARRAY in out case).
>
> This Intergraph GeoMedia FAQ entry
> http://support.intergraph.com/geomedia/faq.asp#97 indicates that the
> number of coordinates I'm trying to add may be maxing out the number
> allowed in an Oracle SDO array.  But why would it work ok creating a
> table but fail for an append?  I tried the command without "-update"
> and it fails then too.

Dave,

There are two implementations of CreateFeature().
One creates a complete textual INSERT statement
while the other uses bound variables for some objects,
including the geometry.  I suspect that creating a new
layer is using the "unbound", and the append is
using the "bound" method.  But I'm not exactly sure
why this would be.  Looking through the code, the
MULTI_LOAD option controls this.  Are you using
that by any chance?  Note that layer creation options
are ignored in the -append case since the layer isn't
actually being created.

Do you have a geometry with more than a million
vertices?

Best regards,
--
---------------------------------------+--------------------------------------
I set the clouds in motion - turn up   | Frank Warmerdam, warmerdam at pobox.com
light and sound - activate the windows | http://pobox.com/~warmerdam
and watch the world go round - Rush    | Geospatial Programmer for Rent




More information about the Gdal-dev mailing list