[gdal-dev] Is there a way to create a spatial index in FGB if created without?

Even Rouault even.rouault at spatialys.com
Thu Nov 24 10:12:22 PST 2022


Mike,

Le 24/11/2022 à 18:56, michael.smith.erdc at gmail.com a écrit :
>
> Basically, can one create a spatial index in a flatgeobuf file if the 
> source does not have one?
>
yes, through ogr2ogr by creating a new file, as you did
>
> Also, when trying to just create a new flatgeobuf with a spatial index 
> from one without (using ogr2ogr), I get a lot of
>
>
> ERROR 2: ICreateFeature: Too big feature
>
It could be either a huuuuge feature whose serialized form exceeds 2GB 
(unlikely, and even more if you convert from an existing flatgeobuf file 
which enforces this limit). Or that you have lots of features and a 
modest amount of RAM. The creation of the spatial index requires an 
amount of RAM proportional to the number of features (maybe 80 bytes or 
so per feature). In this later case, the error message is misleading 
currently. I've just changed it to "ICreateFeature: Memory allocation 
failure" in master.

Even


-- 
http://www.spatialys.com
My software is free, but my time generally not.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: <http://lists.osgeo.org/pipermail/gdal-dev/attachments/20221124/53ac2fb3/attachment.htm>


More information about the gdal-dev mailing list