Is there any way I can define a 3D solid within SQL Server using the spatial data type?
If so, can I see an example of how this would be done? say, just a 1x1x1 simple cube? Would I have to define 6 polygons (1 for each face of the cube) and use those together somehow?
Everything I have read online tends to show examples purely with 2D shapes. I do know the Point type can handle X,Y,Z (and M) - So spatial 3D is possible, but I am finding it hard to get good examples. Especially of polygons / solids.
I guess if this is possible, it leads onto my next question: I would love to use some of the spatial methods that are available: STIntersection(), STContains() etc. Against these 3D objects. And because we are in 3D, a STVolume() function would be fantastic! But that is something I would have to roll myself I guess.
Perhaps there is a library full of SQL CLR Types and Spatial Extension methods that I am in need of?
Thank you.
3D spatial objects have been requested (on Connect: Provide support for 3D Geo-Spatial Data) as far back as 2008.
As you mentioned, it is possible to utilise X,Y,Z and M to represent points with elevation, but there is no direct support for manipulating 3D objects yet.
Ref.
There was no mention of this or other 3D features in New Spatial Features in SQL Server 2012