[BM SS4] .NET Spatial Posting Error

While posting a selection of features to SQL*Server Native Feature Collection, the following was received:

Error Inserting Feature (class: microstation_gis_dbo_SiteUsePermit, id: 11)
A .NET Framework error occurred during execution of user-defined routine or aggregate "GetPlanarGeometryTessellation_VarBinary":
System.FormatException: 24211: The specified operation cannot run under the current compatibility level. A common reason for this issue is that object contains circular arcs. Change the database compatibility level to 110 or higher, or use STCurveToLine.
System.FormatException:
at Microsoft.SqlServer.Types.SqlGeometry.Construct(GeoData g, Int32 srid)
at Microsoft.SqlServer.Types.GeometryTessellationFunction.InitMethod(SqlGeometry geometryObject, Double rootX, Double rootY, Double maxX, Double maxY, Int32 densityGrid0, Int32 densityGrid1, Int32 densityGrid2, Int32 densityGrid3, Int32 cardinality, Int32 tessellationMode, SqlDouble distanceBuffer)
.
The statement has been terminated.

So, I have two questions:

1) Is it recommended to adjust the "database compatibility" as recommended?

2) When this error occurs while processing many features, is there any way to determine which specific feature is causing the issue? FilePos, ElementID, UUID ?

Thanks,

Bruce

  • Hi. The error message says the error occured "...during execution of user-defined routine or aggregate "GetPlanarGeometryTessellation_VarBinary"". Have you defined any function, stored procedure or otherwise that runs on the server when a row is inserted into the table ? I don't think this function comes from Bentley Map so I am wondering if there is something in your database that needs to run...

      

  • The database in question had the DATABASE_COMPATIBILITY value set to "100" (SQL*Server 2008, I believe). It was then upgraded by IT to SQL*Server 2012. I contacted the IT folks and requested them to increase the level to 110 (as recommended) and my last attempt to "post" an ellipse was successful. I guess even thought the database was upgraded, the DATABASE_COMPATIBILITY setting remained unchanged.

    Answer Verified By: Dan Weston