locked
Spatial Reference System (SRID) for perfect sphere? RRS feed

  • Question

  • Hi,  We store all our astronomical objects as coordinates on the celestial sphere (a perfectly round sphere enclosing the earth). Coordinates are always designated by angles (similar to lat. and long.). I was hoping to utilize the new geography data type especially for the indexing capabilities, however, I looked through the 390 SRIDs supported in SQL Server and found that none of them are a perfect sphere (like ESPG 4047 or 3785 for example). This leads me to my question:

    Is it possible for users to upload other reference systems like ESPG 4047 or to create their own reference systems? For example, to create a spheroid with a semi-major axis of 1 and and a flattening ratio of 0? I noticed that adding rows to sys.spatial_reference_systems is not allowed in SQL Server 2008. Is there maybe a system stored procedure for this?

    Any input would be appreciated. Thank you.

     

     

    Wednesday, April 14, 2010 10:28 PM

Answers

  • Area, Length and Distance calculations depend on SRIDs, spatial index and relations (STIntersects and similar operations) do not. It all comes down to which operation you want to use.

    Currently you cannot add custom SRID.

    • Marked as answer by TripleScience Thursday, September 2, 2010 9:05 PM
    Tuesday, April 27, 2010 12:44 PM
  • You can always go to https://connect.microsoft.com/SQLServer/ and ask for new feature.

    If you ask loud enough this might just be done :)

    • Marked as answer by TripleScience Thursday, September 2, 2010 9:05 PM
    Monday, July 26, 2010 4:55 PM

All replies

  • Area, Length and Distance calculations depend on SRIDs, spatial index and relations (STIntersects and similar operations) do not. It all comes down to which operation you want to use.

    Currently you cannot add custom SRID.

    • Marked as answer by TripleScience Thursday, September 2, 2010 9:05 PM
    Tuesday, April 27, 2010 12:44 PM
  • The geography datatype is currently only really usable to describe objects on the Earth's surface, not for astronomical objects in space. Even if you could add a SRID to sys.spatial_reference_systems it wouldn't help, since spatial calculations only operate on the two-dimensional curved surface - they don't take account of elevation.

    You could still store your coordinate data using the geometry datatype, but you'd have to create your own functions to perform calculations on that data.

     

     


    Beginning Spatial with SQL Server http://www.apress.com/book/view/1430218290
    Tuesday, April 27, 2010 9:08 PM
    Answerer
  • You can always go to https://connect.microsoft.com/SQLServer/ and ask for new feature.

    If you ask loud enough this might just be done :)

    • Marked as answer by TripleScience Thursday, September 2, 2010 9:05 PM
    Monday, July 26, 2010 4:55 PM