AnsweredAssumed Answered

Create spatial view from two different databases?

Question asked by mbalxnder on Jan 16, 2014
Latest reply on Jan 30, 2014 by mbalxnder
I am in the process of setting up our spatial views in ArcGIS 10.1 SP1, ArcSDE 10.1 SP1, SQLServer 2008R2. Due to some other geometric network issues, we have to have all of our data in SDEBINARY and cannot store it in Geometry at this time (currently this is non-negotiable). According to ESRI, in order to create a spatial view with SDEBINARY data you have to use the command line sdetable -o create_view. I am able to do this when both feature class and table are in the same database, same instance, but I need to be able to set up a spatial view where the feature class is in one database and the flat table is in another database, same instance.

The correct syntax which created the view with one database (WATER)/two objects is:
sdetable -o create_view -T PLN_DEVELOP_FEE_AREAS_VIEW -t PLN_DEVELOP_FEE_AREAS,FFCIMPORT -c PLN_DEVELOP_FEE_AREAS.Shape,PLN_DEVELOP_FEE_AREAS.IDNumber,FFCIMPORT.IDNum,FFCIMPORT.ProjectNum,PLN_DEVELOP_FEE_AREAS.ObjectID -w "IDNumber=IDNum" -i sde:sqlserver:SQL04V\GIS01 -s SQL04V\GIS01 -D WATER

I thought I should be able to do the following with two databases (WATER & GIS_REPOSITORY_TABLES):
sdetable -o create_view -T PLN_DEVELOP_FEE_AREAS_VIEW -t PLN_DEVELOP_FEE_AREAS,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT -c PLN_DEVELOP_FEE_AREAS.Shape,PLN_DEVELOP_FEE_AREAS.IDNumber,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT.IDNum,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT.ProjectNum,PLN_DEVELOP_FEE_AREAS.ObjectID -w "IDNumber=GIS_REPOSITORY_TABLES.DBO.IDNum" -i sde:sqlserver:SQL04V\GIS01 -s SQL04V\GIS01 -D WATER

or

sdetable -o create_view -T PLN_DEVELOP_FEE_AREAS_VIEW -t WATER.DBO.PLN_DEVELOP_FEE_AREAS,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT -c WATER.DBO.PLN_DEVELOP_FEE_AREAS.Shape,WATER.DBO.PLN_DEVELOP_FEE_AREAS.IDNumber,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT.IDNum,GIS_REPOSITORY_TABLES.DBO.FFCIMPORT.ProjectNum,WATER.DBO.PLN_DEVELOP_FEE_AREAS.ObjectID -w "WATER.DBO.IDNumber=GIS_REPOSITORY_TABLES.DBO.IDNum" -i sde:sqlserver:SQL04V\GIS01 -s SQL04V\GIS01 -D WATER

Could someone please weigh in on this? I was able to do it before we moved to 2008R2 as well as 10.1.

Thank you for your help,
Michelle

Outcomes