<?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: MSSQL server and Spatial query on ArcSDE Database in Data Management Questions</title>
    <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590664#M33367</link>
    <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;GEOMETRY has been the default geometry storage since ArcGIS 10.1, I believe (certainly since 10.2), but that only applies to new installations.&amp;nbsp; SQL-Server 2008R2 is the least recent supported Microsoft database, so you may be using both older ArcGIS and RDBMS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the future, I recommend you post geedatabase management questions in &lt;A _jive_internal="true" href="https://community.esri.com/community/gis/managing-data"&gt;GIS &amp;gt; Managing Data&lt;/A&gt;, and use a "geodatabase" tag, rather than relying on the "every post by time" feed for geodatabase experts to find your post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- V&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
    <pubDate>Fri, 26 Sep 2014 21:23:48 GMT</pubDate>
    <dc:creator>VinceAngelo</dc:creator>
    <dc:date>2014-09-26T21:23:48Z</dc:date>
    <item>
      <title>MSSQL server and Spatial query on ArcSDE Database</title>
      <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590660#M33363</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Hi!&lt;/P&gt;&lt;P&gt;We store our spatial data into a SDE geodatabase (with sde geometry) into a MSSQL server 2008 database.&lt;/P&gt;&lt;P&gt;I need to create a SQL query with spatial relation but need to perform the query onto the database wichi I think will be faster than a tool from ArcGIS.&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;I can do it with model builder or Python but very slow and need to write a table down into the database.&lt;/P&gt;&lt;P&gt;I just need to analyse and return a count of the result...&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;When I was using Oracle my query was :&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;SELECT *&lt;/P&gt;&lt;P&gt;FROM [my_points] pts, [my_area] poly&lt;/P&gt;&lt;P&gt;WHERE CODE_MUN NOT LIKE 'NR%'&lt;/P&gt;&lt;P&gt;and sdo_inside(pts.geoloc,poly.geom) = 'TRUE'&lt;/P&gt;&lt;P&gt;and pts.CODE_MUN &amp;lt;&amp;gt; poly.MUS_CO_GEO&lt;/P&gt;&lt;P style="min-height: 8pt; padding: 0px;"&gt;&amp;nbsp;&lt;/P&gt;&lt;P&gt;How to do this into MSSQL server with sdebinary.&lt;/P&gt;&lt;P&gt;Any idea?&lt;/P&gt;&lt;P&gt;thanks!&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Sep 2014 14:05:35 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590660#M33363</guid>
      <dc:creator>FrancisMoisan</dc:creator>
      <dc:date>2014-09-26T14:05:35Z</dc:date>
    </item>
    <item>
      <title>Re: MSSQL server and Spatial query on ArcSDE Database</title>
      <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590661#M33364</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;SDEBINARY?&amp;nbsp; I don't think it is possible, regardless of Oracle or SQL Server.&amp;nbsp; Are you using SDEBINARY with the code snippet above?&amp;nbsp; It looks like SDO_Geometry.&amp;nbsp; With SQL Server, you would need to use GEOMETRY or GEOGRAPHY.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;Look at STWithin or STContains depending whether you want to look at it from the point's or polygon's perspective.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Sep 2014 15:22:55 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590661#M33364</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2014-09-26T15:22:55Z</dc:date>
    </item>
    <item>
      <title>Re: MSSQL server and Spatial query on ArcSDE Database</title>
      <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590662#M33365</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Thanks,&lt;/P&gt;&lt;P&gt;No the code snippet is the Oracle version of my query.&amp;nbsp; Oracle data where store in native Oracle.&lt;/P&gt;&lt;P&gt;It was so easy...&lt;/P&gt;&lt;P&gt;SDE means using arcgis and I don't like it...&lt;/P&gt;&lt;P&gt;I must validate millions of data with spatial join and performance is not good.&lt;/P&gt;&lt;P&gt;I was using FME to perform sql query (both spatial or not) in Oracle and it was very fast...&lt;/P&gt;&lt;P&gt;I want to reproduce this in MSSQL server with ArcSDE data but can't find a way...&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Sep 2014 19:08:45 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590662#M33365</guid>
      <dc:creator>FrancisMoisan</dc:creator>
      <dc:date>2014-09-26T19:08:45Z</dc:date>
    </item>
    <item>
      <title>Re: MSSQL server and Spatial query on ArcSDE Database</title>
      <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590663#M33366</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;Are you not able to use SQL Server's native spatial types (GEOMETRY, GEOGRAPHY)?&amp;nbsp; Either native spatial type works with ArcSDE and allows one to perform SQL directly against the data.&amp;nbsp; If the data is registered as version, you may need to query the versioned view instead of the base tables.&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Sep 2014 20:02:59 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590663#M33366</guid>
      <dc:creator>JoshuaBixby</dc:creator>
      <dc:date>2014-09-26T20:02:59Z</dc:date>
    </item>
    <item>
      <title>Re: MSSQL server and Spatial query on ArcSDE Database</title>
      <link>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590664#M33367</link>
      <description>&lt;HTML&gt;&lt;HEAD&gt;&lt;/HEAD&gt;&lt;BODY&gt;&lt;P&gt;GEOMETRY has been the default geometry storage since ArcGIS 10.1, I believe (certainly since 10.2), but that only applies to new installations.&amp;nbsp; SQL-Server 2008R2 is the least recent supported Microsoft database, so you may be using both older ArcGIS and RDBMS.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;In the future, I recommend you post geedatabase management questions in &lt;A _jive_internal="true" href="https://community.esri.com/community/gis/managing-data"&gt;GIS &amp;gt; Managing Data&lt;/A&gt;, and use a "geodatabase" tag, rather than relying on the "every post by time" feed for geodatabase experts to find your post.&lt;/P&gt;&lt;P&gt;&lt;/P&gt;&lt;P&gt;- V&lt;/P&gt;&lt;/BODY&gt;&lt;/HTML&gt;</description>
      <pubDate>Fri, 26 Sep 2014 21:23:48 GMT</pubDate>
      <guid>https://community.esri.com/t5/data-management-questions/mssql-server-and-spatial-query-on-arcsde-database/m-p/590664#M33367</guid>
      <dc:creator>VinceAngelo</dc:creator>
      <dc:date>2014-09-26T21:23:48Z</dc:date>
    </item>
  </channel>
</rss>

