Ansicht
Dokumentation

ABENSQL_GEO_CONV_FUNC - SQL GEO CONV FUNC

ABENSQL_GEO_CONV_FUNC - SQL GEO CONV FUNC

General Material Data   CL_GUI_FRONTEND_SERVICES - Frontend Services  
This documentation is copyright by SAP AG.
SAP E-Book

- Geometry Conversion Function

... AS_GEO_JSON( geom ) ...

Effect

The function AS_GEO_JSON reads geometry input in the extended well-known binary (EWKB) representation and returns a geometry object in JSON format. geom must be a table column of type GEOM_EWKB containing a valid geometry. The result is a geometry object in JSON format with data type STRING.

If geom is null, then null is returned.

Notes

  • The geodata type GEOM_EWKB is mapped to the ABAP type xstring. During the conversion to JSON format, a type conversion to the ABAP type string is carried out.
  • AS_GEO_JSON enforces the strict mode from Release .

Example

A geometry is inserted into the DDIC database table DEMO_GEOM_EWKB with the space reference 4326. Within the SELECT statement, the column is read with the built-in function AS_GEO_JSON. The data type is converted from xstring to string and the coordinates of a polygon in JSON format are returned as output.






Addresses (Business Address Services)   PERFORM Short Reference  
This documentation is copyright by SAP AG.

Length: 2190 Date: 20240426 Time: 130500     sap01-206 ( 31 ms )