[prev in list] [next in list] [prev in thread] [next in thread]
List: fdo-trac
Subject: [Fdo-trac] [fdo-trac] #868: Avoid querying NULL values when determine CRS
From: "FDO" <trac_fdo () osgeo ! org>
Date: 2013-07-18 7:04:35
Message-ID: 040.4fc0124dafe0e4963417be8f21a3f92f () osgeo ! org
[Download RAW message or body]
#868: Avoid querying NULL values when determine CRS
---------------------------------+------------------------------------------
Reporter: gBecker | Owner: danstoica
Type: enhancement | Status: new
Priority: minor | Milestone: 3.8.0
Component: SQLServer Spatial | Version: 3.8.0
Severity: 3 | Keywords:
External_id: |
---------------------------------+------------------------------------------
When determine CRS for a table in SQL Server the provider selects the
first row and get the SRID of the geometry.
SELECT TOP 1 [geom].STSrid as srid from [tablename]
If there is no geometry (=NULL) in the first row then the query return
NULL and SRID is treated as 0. So when inserting new geometries they have
the wrong CRS.
In tables where we already have existing geometries it would be nice when
we can enhance the query to avoid selecting NULLs:
SELECT TOP 1 [geom].STSrid as srid from [tablename] WHERE [geom] IS NOT
NULL
I suppose there are other places where this has to be changed. For example
when querying all the spatial indexes to get a list of CRS used in a
FeatureSource (Autodesk Infrastructure Studio / Maestro)
--
Ticket URL: <http://trac.osgeo.org/fdo/ticket/868>
FDO <http://fdo.osgeo.org/>
Feature Data Objects
_______________________________________________
fdo-trac mailing list
fdo-trac@lists.osgeo.org
http://lists.osgeo.org/mailman/listinfo/fdo-trac
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic