Union of several linestring to multilinestring using MS SQL Server

المشرف العام

Administrator
طاقم الإدارة
Followed Postgreql query is the existing one used to combine serveral linestring to a single multilinestring. is there any equivalent of this in SQLServer .

SELECT ST_AsText(ST_Collect(ARRAY[ST_GeomFromText('LINESTRING(1 2, 3 4)'), ST_GeomFromText('LINESTRING(3 4, 4 5)')])) As wktcollect;This is the sample query . My input will be multiples of Linestrings . (Eg: LINESTRING(1 2, 3 4)) which comes dynamically .

Kindly execute this in Postgresql . you will get a clubbed Linestrings as single MultiLinestrings .

Same result required in SQL server . Kindly Help me in this .



أكثر...
 
أعلى