ORA-06553: PLS-306: wrong number or type of arguments in call to 'ST_GEOMETRY'

951
1
09-23-2022 05:39 AM
SASIKIRANCHAGANTI
New Contributor

We have created a new table and tried to insert a record in it.

Tried insert data for a point feature which has ST_GEOMETRY in Arcmap. But the insert statement throwing an error for arguments inside the SDE.ST_GEOMETRY. Data is exported from the same database using sql developer.

Below are the statements with SDE.ST_GEOMETRY

--SDE.ST_GEOMETRY

create table TEST (OBJECTID number(10),SHAPE sde.st_geoemtry);

 

Insert into TEST (OBJECTID,SHAPE) values (233313,SDE.ST_GEOMETRY(1,1,-431957.171802968,1960785.64391692,-431957.171802968,1960785.64391692,NULL,NULL,NULL,NULL,0,0,300002,'oracle.sql.BLOB@3c0b1c3e'));

Below are the statements with MDSYS.ST_GEOMETRY

--With MDSYS.ST_GEOMETRY
create table TEST (OBJECTID number(10),SHAPE MDSYS.st_geoemtry);

 

Insert into TEST (OBJECTID,SHAPE) values (233313,MDSYS.ST_GEOMETRY(1,1,-431957.171802968,1960785.64391692,-431957.171802968,1960785.64391692,NULL,NULL,NULL,NULL,0,0,300002,'oracle.sql.BLOB@3c0b1c3e'));

Error:

SQL Error: ORA-06553: PLS-306: wrong number or type of arguments in call to 'ST_GEOMETRY'

06553. 00000 -  "PLS-%s: %s"

SASIKIRANCHAGANTI_0-1663936537350.png

 

 

0 Kudos
1 Reply
ChrisUnderwood
Esri Contributor

There seems to be a typo in your definition of the SDE.ST_GEOMETRY Table.

create table TEST (OBJECTID number(10),SHAPE sde.st_geoemtry);

Particular questions regarding MDSYS.ST_GEOMETRY syntax may be better answered by Oracle themselves, as that's a type that is created and maintained by them.

https://support.esri.com/en/technical-article/000010625