Hi,
Environment: Windows Server 2008 R2 Standard, Oracle 11g, ArcGisServer 10.1 SP1
Using an existing Feature class, CADASTRE, I created an Oracle view as follows:
CREATE OR REPLACE FORCE VIEW "CADASTRE_TEST" (
"OBJECTID",
"CADID",
"LOTNUMBER",
"SECTIONNUMBER",
"PLANNUMBER",
"PLANLABEL",
"SHAPE")
AS
select /*+FIRST_ROWS*/ c.objectid, c.cadid, c.lotnumber, c.sectionnumber, c.plannumber, c.planlabel, c.shape
from CADASTRE c;
As you can see this is about as basic as it gets. There is no join etc. The only thing it does it select a subset of columns. In theory this should be faster than selecting * on CADASTRE. I tried it with and without the /*+FIRST_ROWS*/ hint.
I then described the feature class CADASTRE using sde as follows:
sdelayer -o describe_long -l CADASTRE,SHAPE -i sde:oracle11g:xxx -u GIS -p xxx (xxx is dumy)
From that I worked out the shape data type, the SRID and the feature types. I then registered CADASTRE_TEST with sde as follows:
sdelayer -o register -l CADASTRE_TEST,SHAPE -e nac+ -t ST_GEOMETRY -C OBJECTID,USER -R 7 -i sde:oracle11g:xxx -u GIS -p xxx
The spatial view is then visible, selectable, identifiable etc in ArcMap/ArcCatalog. However, it is very slow. It is almost as if the spatial view is not using the spatial index from the feature class?
Any ideas? Thank you in advance.