<?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 Re: Create spatial view from two different databases? in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2036#M139</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Nope. I just reran the query on a machine that still has ArcGIS Desktop 10.0 SP5 and ArcSDE 10.0 SP5. Ran the following query using two different databases (one spatial (WATER - SDE), one not (GIS_REPOSITORY_TABLES - non-spatial) and was able to create the spatial view. &lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;In addition, I can also create a spatial view using 10.1 SDE SP1 command line back to a 10.0 SDE database.&lt;/SPAN&gt;&lt;SPAN&gt; I cannot use 10.0 SDE SP5 command line (or toolboxes) back to a 10.1 SDE database.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;O:\&amp;gt;sdetable -o create_view -T PLN_DEVELOP_FEE_AREAS_VIEW_2 -t wtr.PLN_DEVELOP_F&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;EE_AREAS,GIS_Repository_Tables.dbo.FFCIMPORT -c wtr.PLN_DEVELOP_FEE_AREAS.Shape,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;wtr.PLN_DEVELOP_FEE_AREAS.IDNumber,GIS_Repository_Tables.dbo.FFCIMPORT.IDNum,GIS&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;_Repository_Tables.dbo.FFCIMPORT.ProjectNum,wtr.PLN_DEVELOP_FEE_AREAS.ObjectID -&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;w "wtr.PLN_DEVELOP_FEE_AREAS.IDNumber=GIS_Repository_Tables.dbo.FFCImport.IDNum"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; -i sde:sqlserver:GS005 -s GS005 -D WATER&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ArcSDE 10.0&amp;nbsp; for SQL Server Build 685 Fri May 14 12:05:43&amp;nbsp; 2010&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Attribute&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Administration Utility&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-----------------------------------------------------&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Successfully created view PLN_DEVELOP_FEE_AREAS_VIEW_2.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 17 Jan 2014 13:15:40 GMT</pubDate>
    <dc:creator>MichelleBoivin</dc:creator>
    <dc:date>2014-01-17T13:15:40Z</dc:date>
    <item>
      <title>Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2032#M135</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;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.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;The correct syntax which created the view with one database (WATER)/two objects is:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;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&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;I thought I should be able to do the following with two databases (WATER &amp;amp; GIS_REPOSITORY_TABLES):&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;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&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;or&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;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&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Could someone please weigh in on this? I was able to do it before we moved to 2008R2 as well as 10.1.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Thank you for your help,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Michelle&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 17:18:20 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2032#M135</guid>
      <dc:creator>MichelleBoivin</dc:creator>
      <dc:date>2014-01-16T17:18:20Z</dc:date>
    </item>
    <item>
      <title>Re: Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2033#M136</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Esri hasn't supported cross-database queries in a long time.&amp;nbsp; Your work-around is&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;to make an empty table with same layout in the local database, join to that, and then&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;edit the join.&amp;nbsp; Be aware, though, that the cross-database performance cost will be &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;daunting.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 18:20:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2033#M136</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2014-01-16T18:20:40Z</dc:date>
    </item>
    <item>
      <title>Re: Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2034#M137</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;BLOCKQUOTE class="jive-quote"&gt;Esri hasn't supported cross-database queries in a long time.&amp;nbsp; Your work-around is&lt;BR /&gt;to make an empty table with same layout in the local database, join to that, and then&lt;BR /&gt;edit the join.&amp;nbsp; Be aware, though, that the cross-database performance cost will be &lt;BR /&gt;daunting.&lt;BR /&gt;&lt;BR /&gt;- V&lt;/BLOCKQUOTE&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Vince, is this a 10.1 limitation? Below is a spatial view from 10.0 SP5, SQL 2005 that works where the table is stored in a separate database from the feature class (TPW vs. CFWGIS)....&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;SELECT&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sde.TRN_STREET_PMA.Shape, sde.TRN_STREET_PMA.OBJECTID, sde.TRN_STREET_PMA.SECT_NO, TPW.dbo.PMA_STREETS.Street_Name, TPW.dbo.PMA_STREETS.gis_dir AS Dir, TPW.dbo.PMA_STREETS.Divided AS Divided_Street, TPW.dbo.PMA_STREETS.Storm_Water_Needs, TPW.dbo.PMA_STREETS.Traffic_Lane&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;FROM&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; sde.TRN_STREET_PMA INNER JOIN TPW.dbo.PMA_STREETS ON sde.TRN_STREET_PMA.SECT_NO = TPW.dbo.PMA_STREETS.sect_no&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 19:58:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2034#M137</guid>
      <dc:creator>MichelleBoivin</dc:creator>
      <dc:date>2014-01-16T19:58:24Z</dc:date>
    </item>
    <item>
      <title>Re: Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2035#M138</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;I believe optional cross-database access was eliminated at ArcSDE &lt;/SPAN&gt;&lt;STRONG&gt;9.1&lt;/STRONG&gt;&lt;SPAN&gt;.&amp;nbsp; You'd have to go&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; back into 8.x for the last time I named a database "sde", so I don't know if that changes&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;the tolerance for multi-database model support.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Are you sure the view wasn't doctored with the same technique?&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;- V&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 16 Jan 2014 22:33:24 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2035#M138</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2014-01-16T22:33:24Z</dc:date>
    </item>
    <item>
      <title>Re: Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2036#M139</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;Nope. I just reran the query on a machine that still has ArcGIS Desktop 10.0 SP5 and ArcSDE 10.0 SP5. Ran the following query using two different databases (one spatial (WATER - SDE), one not (GIS_REPOSITORY_TABLES - non-spatial) and was able to create the spatial view. &lt;/SPAN&gt;&lt;SPAN style="font-style:italic;"&gt;In addition, I can also create a spatial view using 10.1 SDE SP1 command line back to a 10.0 SDE database.&lt;/SPAN&gt;&lt;SPAN&gt; I cannot use 10.0 SDE SP5 command line (or toolboxes) back to a 10.1 SDE database.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;O:\&amp;gt;sdetable -o create_view -T PLN_DEVELOP_FEE_AREAS_VIEW_2 -t wtr.PLN_DEVELOP_F&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;EE_AREAS,GIS_Repository_Tables.dbo.FFCIMPORT -c wtr.PLN_DEVELOP_FEE_AREAS.Shape,&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;wtr.PLN_DEVELOP_FEE_AREAS.IDNumber,GIS_Repository_Tables.dbo.FFCIMPORT.IDNum,GIS&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;_Repository_Tables.dbo.FFCIMPORT.ProjectNum,wtr.PLN_DEVELOP_FEE_AREAS.ObjectID -&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;w "wtr.PLN_DEVELOP_FEE_AREAS.IDNumber=GIS_Repository_Tables.dbo.FFCImport.IDNum"&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt; -i sde:sqlserver:GS005 -s GS005 -D WATER&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;ArcSDE 10.0&amp;nbsp; for SQL Server Build 685 Fri May 14 12:05:43&amp;nbsp; 2010&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Attribute&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp;&amp;nbsp; Administration Utility&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;-----------------------------------------------------&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;Successfully created view PLN_DEVELOP_FEE_AREAS_VIEW_2.&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 17 Jan 2014 13:15:40 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2036#M139</guid>
      <dc:creator>MichelleBoivin</dc:creator>
      <dc:date>2014-01-17T13:15:40Z</dc:date>
    </item>
    <item>
      <title>Re: Create spatial view from two different databases?</title>
      <link>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2037#M140</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;SPAN&gt;So the overall answer to this ended up being the following (below) per an ESRI Incident I entered. I tested it and it works, however if you have numerous views to create and maintain on a regular basis, this is definitely NOT the best practice. In addition, ESRI does not fully support this process in that they do not support modifications on the back-end. Please keep in mind that this is for data stored in SDEBINARY. If your data is stored in the GEOMETRY type, you can use the DatabaseView tool in 10.1 to create a cross-database spatial view.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;1. Import a copy of the SQL table in question into the ArcSDE database as the owner of the data.&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;2. Create a view on this table in the ArcSDE database using the following sde command syntax: &lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;sdetable -o create_view -T -t -c -w -i -s -D -u -p&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;For example:&lt;/SPAN&gt;&lt;BR /&gt;&lt;SPAN&gt;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 "FFCImport.IDNumber=PLN_DEVELOP_FEE_AREAS.IDNum" -i sde:sqlserver:&amp;lt;server&amp;gt; -s &amp;lt;server&amp;gt; -D WATER&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;3. Grant the ArcSDE table and view owner permissions to the original non-ArcSDE database and table. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;4. Edit the view design within SQL server to reference the original table stored in the non-ArcSDE database. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;5. Drop the copied table within the ArcSDE database. The view should now be pointing to the original table located within the non-ArcSDE database. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Verify all necessary permissions have been granted to the table within the non-ArcSDE database in order to see the contents of the view within ArcCatalog. &lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;Hope this helps some of you out there.......&lt;/SPAN&gt;&lt;BR /&gt;&lt;BR /&gt;&lt;SPAN&gt;~Michelle&lt;/SPAN&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Thu, 30 Jan 2014 19:10:34 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/create-spatial-view-from-two-different-databases/m-p/2037#M140</guid>
      <dc:creator>MichelleBoivin</dc:creator>
      <dc:date>2014-01-30T19:10:34Z</dc:date>
    </item>
  </channel>
</rss>

