Learn R Programming

rpostgis (version 1.0.0)

pgGetBoundary: Retrieve bounding envelope of geometries or rasters.

Description

Retrieve bounding envelope (rectangle) of all geometries or rasters in a Postgresql table.

Usage

pgGetBoundary(conn, name, geom = "geom")

Arguments

conn
A connection object to a PostgreSQL database
name
A character string specifying a PostgreSQL schema (if necessary), and table or view name for the table holding the geometries/raster(s) (e.g., name = c("schema","table"))
geom
character, Name of the column in 'name' holding the geometry or raster object (Default = 'geom')

Value

SpatialPolygon

Examples

Run this code
## Not run: 
# pgGetBoundary(conn, c("schema", "polys"), geom = "polygon")
# pgGetBoundary(conn, c("schema", "rasters"), geom = "rast")
# ## End(Not run)

Run the code above in your browser using DataLab