Skip to content

Latest commit

 

History

History
60 lines (45 loc) · 1.96 KB

File metadata and controls

60 lines (45 loc) · 1.96 KB
title STMPolyFromWKB (geometry Data Type)
description STMPolyFromWKB (geometry Data Type)
author MladjoA
ms.author mlandzic
ms.date 08/03/2017
ms.service sql
ms.subservice t-sql
ms.topic reference
ms.custom
ignite-2024
f1_keywords
STMPolyFromWKB (geometry Data Type)
STMPolyFromWKB_TSQL
helpviewer_keywords
STMPolyFromWKB (geometry Data Type)
dev_langs
TSQL

STMPolyFromWKB (geometry Data Type)

[!INCLUDE SQL Server Azure SQL Database Azure SQL Managed Instance FabricSQLDB]

Returns a geometryMultiPolygon instance from an Open Geospatial Consortium (OGC) Well-Known Binary (WKB) representation.

Syntax

  
STMPolyFromWKB ( 'WKB_multipolygon' , SRID )  

Arguments

WKB_multipolygon
Is the WKB representation of the geometryMultiPolygon instance you wish to return. WKB_multipolygon is a varbinary(max) expression.

SRID
Is an int expression representing the spatial reference ID (SRID) of the geometryMultiPolygon instance you wish to return.

Return Types

[!INCLUDEssNoVersion] return type: geometry

CLR return type: SqlGeometry

OGC type: MultiPolygon

Remarks

Examples

The following example uses STMPolyFromWKB() to create a geometry instance:

DECLARE @g geometry;   
SET @g = geometry::STMPolyFromWKB(0x0106000000020000000103000000010000000400000000000000000014400000000000001440000000000000244000000000000014400000000000002440000000000000244000000000000014400000000000001440010300000001000000050000000000000000002440000000000000244000000000000059400000000000002440000000000000694000000000000069400000000000003E400000000000003E4000000000000024400000000000002440, 0);  
SELECT @g.STAsText();  

See Also

OGC Static Geometry Methods