RefLib

Reference library for AI

Back

postgresql_16:3.5.8.5 Paths

PostgreSQL 16 > The SQL Language > Data Types > Geometric Types > Paths

Paths are represented by lists of connected points. Paths can be *open*, where the first and last points in the list are considered not connected, or *closed*, where the first and last points are considered connected.

Values of type path are specified using any of the following syntaxes: [ ( *x1* , *y1* ) , ... , ( *xn* , *yn* ) ] ( ( *x1* , *y1* ) , ... , ( *xn* , *yn* ) ) ( *x1* , *y1* ) , ... , ( *xn* , *yn* ) ( *x1* , *y1* , ... , *xn* , *yn* ) *x1* , *y1* , ... , *xn* , *yn* where the points are the end points of the line segments comprising the path. Square brackets ([]) indicate an open path, while parentheses (()) indicate a closed path. When the outermost parentheses are omitted, as in the third through fifth syntaxes, a closed path is assumed.

Paths are output using the first or second syntax, as appropriate.

Back