File: node.sql

package info (click to toggle)
postgis 3.5.3%2Bdfsg-1
  • links: PTS, VCS
  • area: main
  • in suites: sid
  • size: 69,528 kB
  • sloc: ansic: 162,229; sql: 93,970; xml: 53,139; cpp: 12,646; perl: 5,658; sh: 5,369; makefile: 3,435; python: 1,205; yacc: 447; lex: 151; pascal: 58
file content (20 lines) | stat: -rw-r--r-- 549 bytes parent folder | download | duplicates (6)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
-- Node two crossing lines
select 't1', st_asewkt(st_node(
'SRID=10;MULTILINESTRING((0 0, 10 0),(5 -5, 5 5))'
));

-- Node two overlapping lines
select 't2', st_asewkt(st_node(
'SRID=10;MULTILINESTRING((0 0, 10 0, 20 0),(25 0, 15 0, 8 0))'
));

-- Node a self-intersecting line
-- See http://trac.osgeo.org/geos/ticket/482
select 't3', st_asewkt(st_node(
'SRID=10;LINESTRING(0 0, 10 10, 0 10, 10 0)'
));

-- Node two overlapping 3d lines, from documentation
select 't4', st_asewkt(st_node(
'SRID=10;LINESTRINGZ(0 0 0, 10 10 10, 0 10 5, 10 0 3)'
));