We store our spatial data into a SDE geodatabase (with sde geometry) into a MSSQL server 2008 database.
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.
I can do it with model builder or Python but very slow and need to write a table down into the database.
I just need to analyse and return a count of the result...
When I was using Oracle my query was :
FROM [my_points] pts, [my_area] poly
WHERE CODE_MUN NOT LIKE 'NR%'
and sdo_inside(pts.geoloc,poly.geom) = 'TRUE'
and pts.CODE_MUN <> poly.MUS_CO_GEO
How to do this into MSSQL server with sdebinary.