0

I'm running a number of Spatial Functions in DB2 (11.5 LUW) and getting back errors such as:

SQL Error [42884]: No authorized routine named "ST_ENDPOINT" of type "FUNCTION" having compatible arguments was found.. SQLCODE=-440, SQLSTATE=42884, DRIVER=4.31.10

This is happening for a number of spatial functions:

  • ST_EndPoint
  • ST_Relate
  • ST_ExteriorRing
  • ST_InteriorRingN
  • ST_Intersection
  • ST_IsRing
  • ST_NumGeometries
  • ST_NumInteriorRing
  • ST_PointN
  • ST_Relate
  • ST_StartPoint

Other geometry functions seem to work fine and I'm calling them with db2gse. When I look in the database under the db2gse schema, these functions are indeed missing. Do I have a corrupted database here? Or is there some other way to reference these functions?

UPDATE

I created a brand new database and enabled it for spatial extensions using:

db2se enable_db MYDB

This new database is still missing all the above functions. Am I missing something?

asked Sep 6, 2023 at 4:12

1 Answer 1

0

Looks like the documentation is inaccurate.

The following will work as an example for ST_EndPoint

db2gse.ST_EndPoint(TREAT(geomcol AS db2gse.ST_Curve))

But it won't work if you don't use the TREAT statement. There's no mention of that in the documentation:

https://www.ibm.com/docs/en/db2/11.5?topic=functions-st-endpoint

answered Sep 7, 2023 at 18:30

Your Answer

Draft saved
Draft discarded

Sign up or log in

Sign up using Google
Sign up using Email and Password

Post as a guest

Required, but never shown

Post as a guest

Required, but never shown

By clicking "Post Your Answer", you agree to our terms of service and acknowledge you have read our privacy policy.

Start asking to get answers

Find the answer to your question by asking.

Ask question

Explore related questions

See similar questions with these tags.