All Products
Search
Document Center

PolarDB:ST_RelateMatch

Last Updated:Mar 28, 2026

Tests whether an intersection matrix satisfies an intersection pattern.

Syntax

boolean ST_RelateMatch(text intersectionMatrix, text intersectionMatrixPattern);

Parameters

ParameterDescription
intersectionMatrixThe intersection matrix that you want to specify.
intersectionMatrixPatternThe intersecting pattern that you want to specify.

Examples

The following example shows how ST_RelateMatch evaluates a matrix against a pattern, returning true when the matrix satisfies the pattern.

Match: returns true

SELECT ST_RelateMatch('FF1F00102', 'FF*******');
 st_relatematch
----------------
 t
(1 row)

The matrix 'FF1F00102' starts with FF, which matches the pattern 'FF*******' (the remaining seven positions accept any value).