ST_Touches — Returns `TRUE`

if the geometries have at least one point in common,
but their interiors do not intersect.

`boolean `

geometry
**ST_Touches**(`g1`, geometry
`g2``)`

;

Returns `TRUE`

if the only points in common between
* g1* and

`g2`

`g1`

`g2`

`ST_Touches`

relation applies
to all Area/Area, Line/Line, Line/Area, Point/Area and Point/Line pairs of relationships,
but In mathematical terms, this predicate is expressed as:

*TODO: Insert appropriate MathML markup here or use a gif.
Simple HTML markup does not work well in both IE and Firefox.*

The allowable DE-9IM Intersection Matrices for the two geometries are:

FT*******

F**T*****

F***T****

Do not call with a |

This function call will automatically include a bounding box
comparison that will make use of any indexes that are available on
the geometries. To avoid using an index, use |

This method implements the OpenGIS Simple Features Implementation Specification for SQL: 2.1.1.2, 2.1.13.3

This method implements the SQL/MM specification: SQL-MM 3: 5.1.28

The `ST_Touches`

predicate returns `TRUE`

in all the following illustrations.

SELECT ST_Touches('LINESTRING(0 0, 1 1, 0 2)'::geometry, 'POINT(1 1)'::geometry); st_touches ------------ f (1 row) SELECT ST_Touches('LINESTRING(0 0, 1 1, 0 2)'::geometry, 'POINT(0 2)'::geometry); st_touches ------------ t (1 row)