2 Replies Latest reply: Jan 12, 2014 5:55 PM by 1064020 RSS

    Errors in sdo_util on 12c

    1064020

      I have installed spatial on an Oracle 12C database and I am receiving the error below when using sdo_util.to_wktgeometry. Some of the other sdo_util functions work as expected. I checked the class files and they are all valid. Has anyone else encountered this error.

       

      ORA-29531: no method structToWktJS in class oracle/spatial/util/Adapters

      ORA-06512: at "MDSYS.SDO_JAVA_STP", line 350

      ORA-06512: at "MDSYS.SDO_UTIL", line 2813

      ORA-06512: at "MDSYS.SDO_UTIL", line 2836

      29531. 00000 -  "no method %s in class %s"

      *Cause:    An attempt was made to execute a non-existent method in a

                 Java class.

      *Action:   Adjust the call or create the specified method.

        • 1. Re: Errors in sdo_util on 12c
          Barbara Boehmer

          I am not getting any error, as shown below, using a few excerpts from the online documentation.  Can you run the same or similar script without error?  Can you post a run of a test case that does produce the error for you?

           

           

          SCOTT@orcl12c> set long 2000;

          SCOTT@orcl12c> SELECT banner FROM v$version;

           

          BANNER

          --------------------------------------------------------------------------------

          Oracle Database 12c Enterprise Edition Release 12.1.0.1.0 - 64bit Production

          PL/SQL Release 12.1.0.1.0 - Production

          CORE    12.1.0.1.0    Production

          TNS for 64-bit Windows: Version 12.1.0.1.0 - Production

          NLSRTL Version 12.1.0.1.0 - Production

           

          5 rows selected.

           

          SCOTT@orcl12c> CREATE TABLE cola_markets

            2    (mkt_id    NUMBER PRIMARY KEY,

            3      name    VARCHAR2(32),

            4      shape    SDO_GEOMETRY);

           

          Table created.

           

          SCOTT@orcl12c> INSERT INTO cola_markets VALUES

            2    (2, 'cola_b',

            3      SDO_GEOMETRY

            4        (2003, NULL, NULL,

            5         SDO_ELEM_INFO_ARRAY (1,1003,1),

            6         SDO_ORDINATE_ARRAY(5,1, 8,1, 8,6, 5,7, 5,1)));

           

          1 row created.

           

          SCOTT@orcl12c> INSERT INTO user_sdo_geom_metadata (TABLE_NAME, COLUMN_NAME, DIMINFO, SRID) VALUES

            2    ('cola_markets', 'shape',

            3      SDO_DIM_ARRAY

            4        (SDO_DIM_ELEMENT('X', 0, 20, 0.005),

            5         SDO_DIM_ELEMENT('Y', 0, 20, 0.005)),

            6      NULL);

           

          1 row created.

           

          SCOTT@orcl12c> CREATE INDEX cola_spatial_idx ON cola_markets(shape) INDEXTYPE IS MDSYS.SPATIAL_INDEX;

           

          Index created.

           

          SCOTT@orcl12c> SELECT SDO_UTIL.TO_WKTGEOMETRY (shape) FROM cola_markets WHERE name = 'cola_b';

           

          SDO_UTIL.TO_WKTGEOMETRY(SHAPE)

          --------------------------------------------------------------------------------

          POLYGON ((5.0 1.0, 8.0 1.0, 8.0 6.0, 5.0 7.0, 5.0 1.0))

           

          1 row selected.

          • 2. Re: Errors in sdo_util on 12c
            1064020

            Thanks for the reply. The example you posted received the error as well. The sdo_util is working in my 11g database so I am thinking that the spatial install on 12c was not done properly. I am going to manually install spatial and see if that resolves the issue. Thanks for your help.