diff --git a/R/gpkg_bbox.R b/R/gpkg_bbox.R index 8d62457..2aaea83 100644 --- a/R/gpkg_bbox.R +++ b/R/gpkg_bbox.R @@ -21,11 +21,11 @@ #' gpkg_bbox(g, 'bbox') #' } gpkg_bbox <- function(x, table_name, geom_column = "geom") { - as.data.frame(gpkg_ogr_query(x, paste0(gsub("geom", geom_column, + as.data.frame(gpkg_ogr_query(x, paste(gsub("geom", geom_column, "SELECT ST_MinX(geom) AS xmin, ST_MinY(geom) AS ymin, ST_MaxX(geom) AS xmax, ST_MaxY(geom) AS ymax - FROM ", table_name)))) + FROM"), table_name))) } \ No newline at end of file