Geospatial data

Overview

Geospatial data on Redivis behaves quite similarly to tabular data: each feature is ingested as a single row within a table, alongside any metadata for this feature. This approach mirrors tools like PostGIS, R spatial features, and geopandas, allowing you to query and join your geospatial data, at scale.

Supported file types

Redivis supports importing geospatial data from several common GIS formats: geojson, shp, shp.zip,kml, and parquet. Parquet files with geospatial metadata (often referred to as GeoParquet) are the most performant and robust option, though as a newer standard, these files are less common. For other geospatial file types, Redivis first converts the file to a geojson representation (using the relevant ogr2ogr driver), and then imports the geojson into a table.

Each feature will be imported as one row, with the geometry column containing the WKT representation for that feature. Additional feature properties will be mapped to variables in your table, with any nested properties flattened using the . separator. Note that Redivis only supports 2-dimensional, unprojected (WGS84) geometries. Other projections might cause the import to fail, and any extra dimensions will be stripped during ingest. If you are uploading a .shp.zip that contains projection information, the geometries will automatically be reprojected as part of the import process.

Type
Description
Notes

.parquet

GeoParquet

The GeoParquet specification is a modern standard for working with column-oriented geospatial data. If available, this format is the most robust and performant way to ingest geospatial features into Redivis.

.geojson

GeoJSON

Assumes an object with a "Features" property, containing an array of valid geojson features. Each feature will be imported as one row, with additional properties mapped to columns in the table. Nested properties will be flattened using the . separator. Note that Redivis only supports 2-dimensional, unprojected (WGS84) geometries. Other projections might cause the import to fail, and any extra dimensions will be stripped during ingest. See working with geospatial data for more information.

.geojsonl, .ndgeojson .geojsons

Same as the .geojson specification outlined above, except each feature is given its own line. Importing .geojsonl (as opposed to .geojson) will be significantly faster.

.kml

Keyhole Markup Language

Will be internally converted to .geojson (via ogr2ogr), and then imported as specified above.

.shp

Shapefile

Will be internally converted to .geojson (via ogr2ogr), and then imported as specified above. Note that the shapefile must use the WGS84 (aka EPSG:4326) projection. If you have additional files associated with your shapefile (e.g., .shx, .proj, .dbf), create a .zip of this folder and import according to the .shp.zip specification below.

.shp.zip

Zipped ESRI shapefile directory

Many shapefiles will be collocated with additional files containing metadata and projection information. These files are often essential to parsing the shapefile correctly, and should be uploaded together. To do so, create a .zip directory of the folder containing your .shp file and supplemental files. The zip file must end in .shp.zip. These will then be converted to .geojson (via ogr2ogr), and imported as specified for the .geojson format.

If projection information is available, the source geometries will be reprojected into WGS84. If no projection information is available, your data must be projected as WGS84, or the import will fail. Note that only one layer can be imported at a time. If you have directory containing multiple shapefiles, create a separate .shp.zip for each layer.

Geography data in text-delimited files

In addition to uploading geospatial data using one of the formats listed above, you can also import geographic data encoded within a text-delimited file (e.g., a csv). In this case, the geographic data should be encoded as strings using the Well-Known Text (WKT) representation. This is also the same format used when exporting geography variables as a CSV. WKT in CSVs will be auto-detected during data ingest.

Quotas & limits

Limits for upload file size, max variables, and other parameters are specified here.

Last updated