rpostgis (version 1.4.3)

pgGetBoundary: Retrieve bounding envelope of geometries or rasters.

Description

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

Usage

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

Value

SpatialPolygon

Arguments

conn

A connection object to a PostgreSQL database

name

A character string specifying a PostgreSQL schema and table/view name holding the geometry (e.g., name = c("schema","table"))

geom

character, Name of the column in name holding the geometry/(geography) or raster object (Default = "geom")

clauses

character, additional SQL to append to modify select query from table. Must begin with an SQL clause (e.g., "WHERE ...", "ORDER BY ...", "LIMIT ..."); same usage as in pgGetGeom.

Author

David Bucklin david.bucklin@gmail.com

Examples

Run this code
if (FALSE) {
pgGetBoundary(conn, c("schema", "polys"), geom = "polygon")
pgGetBoundary(conn, c("schema", "rasters"), geom = "rast")
}

Run the code above in your browser using DataLab