ArcSDE Notes

From NGDCWiki

Jump to: navigation, search

Contents

Oracle spatial vs. sde binary

  • Oracle Spatial tables cannot be copied using cut-and-paste in ArcCatalog

sdelayer vs. sdetable

sdelayer -o delete and sdetable -o delete function differently, especially in the case of SDO_GEOMETRY tables

  • sdelayer
    • removes the corresponding record from SDE.LAYERS, SDE.GEOMETRY_COLUMNS, and (in case of SDO_GEOMETRY tables) from user_sdo_geom_metadata view.
    • It also drops the F_<LAYER_ID>, F_<LAYER_ID> tables when the layer is an SDEBINARY.
    • sdelayer does not drop the layer's business table (which for SDO_GEOMETRY layers is the same as the geometry table).
    • Since the business table remains there is a corresponding record in SDE.TABLE_REGISTRY.
    • Dropping the table via SQL at this point leaves an orphaned record in the ArcSDE repository.
  • sdetable
    • deletes the layer *and* table in one step.
    • It also removes the corresponding record from SDE.LAYERS, SDE.GEOMETRY_COLUMNS, SDE.TABLE_REGISTRY, and (in case of SDO_GEOMETRY tables) from user_sdo_geom_metadata view.

Feature Classes

  • IMPORTANT: if a layer has been loaded via ArcCatalog it is a full Feature Class and should not be removed via sdelayer/sdetable.
    • Doing so will leave orphaned records in the SDE.GDB_% tables
    • "sdelayer -o delete" will delete the SDE registration and remove record from USER_SDO_GEOM_METADATA, but will not drop the table.

SRIDs

  • if a table has an SRID value in USER_SDO_GEOM_METADATA at the time "sdelayer -o register" is run, ESRI will "translate" the oracle definitin and create a new corresponding spatial reference. This will not be identical to the ESRI spatial reference definition.
  • For example, if oracle has an SRID of 8307 at the time of SDE registration, the sde spatial reference will be slightly different than if the oracle SRID was null as the time of SDE registration and the SDE registration was subsequently altered to 4326 (ESRI's WGS84 code).

Checking for feature geometry validity in SDE

sdelayer -o feature_info -l <table,column> [-V <version>]
                  [-r {valid | all | invalid}] [-w <"where_clause">] [-c]
                  [-s <server_name>] [-D <database>]
                  [-u <DB_User_name>] [-p <DB_User_password>] [-N] [-q]
  • This works against both SDEBINARY and SDO_GEOMETRY tables.
  • It's a good second check to run in addition to ((SpatialValidateLayer|validating with Oracle))

Running SDE on Panther (Linux)

To run SDE on panther without core dumps, the following shell variables must be set:

LD_LIBRARY_PATH=/usr/local/esri/sdeexe83/lib LD_ASSUME_KERNEL=2.4.19


-e Entity types allowed (npsla3+M)

n Nil
p Point shapes
s Line (spaghetti) shapes
l Simple line (line string) shapes
a Area shapes
3 Three-dimensional shapes can be added 
  to the entity type mask with the "-o add" operation only.
+ Multipart shapes
M Measures on coordinates. 
  The [-m] option is required if measures on coordinates is a defined shape type
Personal tools