This function has been deprecated. Please use gpkg_create_empty_features().

gpkg_create_dummy_features(x, table_name = "dummy_feature", values = NULL)

Arguments

x

A geopackage object

table_name

A table name; default "dummy_feature"

values

Values to use for new table. Defaults to default geometry name ("geom"), with generic GEOMETRY data type, with no spatial reference system.

Value

logical. TRUE on success.

Details

Create a minimal (empty) feature table and gpkg_geometry_columns table entry.

This is a workaround so that gpkg_vect() (via terra::vect()) will recognize a GeoPackage as containing geometries and allow for use of OGR query utilities. The "dummy table" is not added to gpkg_contents and you should not try to use it for anything. The main purpose is to be able to use gpkg_vect() and gpkg_ogr_query() on a GeoPackage that contains only gridded and/or attribute data.