Hi everybody.
There was a post in the old ESRI Discussion Forums (http://forums.esri.com/Thread.asp?c=158&f=2291&t=297314) related to slow performance of ArcSDE with Oracle and ST_GEOMETRY feature classes.
We also have the same problems described there. There was an user in this post, "T B", that seems to work at ESRI Inc., that wrote the following:
"I've started KB article 37468, "Oracle's optimizer uses a full table scan when executing a query against a st_geometry attribute" and will hopefully have this published before the year (2009) is over... "
I've been searching for this KB but I haven't found it. "T B", if you read this message, please update us with more information about this problem and tell us if you finally wrote the KB that you were talking about.
Thanks in advance,
Santiago Lastra.
Hi
slow performance in what sense?
We are using oracle sdo_geometry and havent noticed any slowness.
Is it slow when query data in catalog search tool or query one FClass or what?
Was KB 37468 ever written? I can't find it. And several threads ask about its existence. Is there a newer KB article number addressing the issue that supercedes it? The issue being setting the selectivity of the st_envintersects operator to prevent superfluous Full Table Scans on feature classes using ST_GEOMETRY as the shape type.
Wanted to know what the current suggested solution is for ArcSDE 9.3.1. Also, we're running SDE 9.3.1 with no service packs. Do any service packs improve query performance for ST_GEOMETRY? Or do SDE 9.3.1 installations with the latest service pack suffer from the same FTS problem?
Is the following still the best workaround:
This is what I'm recommending, instead of setting the num_rows = 0, please execute the following as the data owner -
From post: http://forums.esri.com/thread.asp?c=158&f=2291&t=297314
[INDENT]DECLARE
CURSOR each_table IS
SELECT table_name, column_name
FROM sde.st_geometry_index
WHERE owner = USER;
BEGIN
FOR each_row IN each_table LOOP
sde.spx_util.set_operator_selectivity(user,each_row.table_name,each_row.column_name,'st_envintersects',.005);
END LOOP;
END;
/ [/INDENT]
Also, can the code above *only* be run as the data owner. As a SDE, I'd prefer to run it as my DBA account. I don't have the password for the data owner.
Further, the SQL being generated is "shrinkwrapped" SQL coming from ArcGIS Explorer 1500 (AGX). So the three KB articles sean4788 referenced above are of no use to us (meaning we can't open up Esri's binaries and force indexes to be used). Those KB articles seem useful only to those writing their own SQL queries and not having them auto-generate in an Esri client like AGX.
Thanks.