<?xml version="1.0" encoding="UTF-8"?>
<rss xmlns:content="http://purl.org/rss/1.0/modules/content/" xmlns:dc="http://purl.org/dc/elements/1.1/" xmlns:rdf="http://www.w3.org/1999/02/22-rdf-syntax-ns#" xmlns:taxo="http://purl.org/rss/1.0/modules/taxonomy/" version="2.0">
  <channel>
    <title>topic Centroid querying errors to Oracle database in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/centroid-querying-errors-to-oracle-database/m-p/592393#M33483</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am attempting to create a query layer in ArcMap 10 to an Oracle database, using the centroid as the geometry for the data. I can't post the actual query, but here is a generalization:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;SELECT TO_CHAR(F.ID) "Unique ID", SDO_Geom.SDO_Centroid(S.Geometry,1) "Centroid"
FROM MyTable F, AnotherTable S
WHERE F.ID = S.MyTable_ID&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Arc is able to validate the query and determime that the geometry type is a Point with unknown spatial reference. I then set the reference to WGS84 (leaving as Unknown doesn't help) and save the query layer. As soon as it attempts to refresh the data, i get the following error:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;One or more layers failed to draw:

MyQuery: Underlying DBMS error [ORA-06553:
PLS-306: wrong number or types of arguments in call to
'OGC_CENTROID'
]&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've run the SQL in SQLDeveloper and the data returns perfectly, so the syntax is correct. Why does Arc call 'OGC_CENTROID', and is this the reason for the query failing? Is there a different Oracle-compatible centroid function that Arc supports?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Sun, 12 Dec 2021 01:26:34 GMT</pubDate>
    <dc:creator>EricSpitler</dc:creator>
    <dc:date>2021-12-12T01:26:34Z</dc:date>
    <item>
      <title>Centroid querying errors to Oracle database</title>
      <link>https://community.esri.com/t5/data-management-questions/centroid-querying-errors-to-oracle-database/m-p/592393#M33483</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I am attempting to create a query layer in ArcMap 10 to an Oracle database, using the centroid as the geometry for the data. I can't post the actual query, but here is a generalization:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;SELECT TO_CHAR(F.ID) "Unique ID", SDO_Geom.SDO_Centroid(S.Geometry,1) "Centroid"
FROM MyTable F, AnotherTable S
WHERE F.ID = S.MyTable_ID&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Arc is able to validate the query and determime that the geometry type is a Point with unknown spatial reference. I then set the reference to WGS84 (leaving as Unknown doesn't help) and save the query layer. As soon as it attempts to refresh the data, i get the following error:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;PRE class="lia-code-sample line-numbers language-none"&gt;One or more layers failed to draw:

MyQuery: Underlying DBMS error [ORA-06553:
PLS-306: wrong number or types of arguments in call to
'OGC_CENTROID'
]&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I've run the SQL in SQLDeveloper and the data returns perfectly, so the syntax is correct. Why does Arc call 'OGC_CENTROID', and is this the reason for the query failing? Is there a different Oracle-compatible centroid function that Arc supports?&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Sun, 12 Dec 2021 01:26:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/centroid-querying-errors-to-oracle-database/m-p/592393#M33483</guid>
      <dc:creator>EricSpitler</dc:creator>
      <dc:date>2021-12-12T01:26:34Z</dc:date>
    </item>
    <item>
      <title>Re: Centroid querying errors to Oracle database</title>
      <link>https://community.esri.com/t5/data-management-questions/centroid-querying-errors-to-oracle-database/m-p/592394#M33484</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I just attempted the query w/o the centroid function (i.e. just pulling the geometry) and it still returned an error about the centroid. Example geometry returned in SQLDeveloper:&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Geometry:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;MDSYS.SDO_GEOMETRY(2003,8307,null,MDSYS.SDO_ELEM_INFO_ARRAY(1,1003,1),MDSYS.SDO_ORDINATE_ARRAY(121.54331,42.109625,121.543454,41.992575,121.700346,41.992575,121.70049,42.109625,121.54331,42.109625))&lt;/PRE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Centroid:&lt;/SPAN&gt;&lt;BR /&gt;&lt;PRE __default_attr="plain" __jive_macro_name="code" class="jive_macro_code jive_text_macro"&gt;MDSYS.SDO_GEOMETRY(2001,8307,MDSYS.SDO_POINT_TYPE(121.6219,42.0511271376152,null),null,null)&lt;/PRE&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Tue, 14 Feb 2012 15:56:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/centroid-querying-errors-to-oracle-database/m-p/592394#M33484</guid>
      <dc:creator>EricSpitler</dc:creator>
      <dc:date>2012-02-14T15:56:34Z</dc:date>
    </item>
  </channel>
</rss>

