开发者

SQL Server Geography datatype: weird behavior

I have an application that has been running for years now with no issues. Recently I decided to add a Geography type column to one of the table开发者_如何学JAVAs, application uses. After doing so, the website on production server started acting up: weird null reference exceptions in places where the table was used. But what's more important, the site ran just fine on my development machine. Please note, that only change i did was to add the column to table. Nothing was changed in DAL or BBL. The data access layer is written using ADO.NED. The only real difference between my Dev machine and Production server is that i have SQL Server 2008 R2 installed on my machine. But still can't figure out why this could have caused application errors. If i ignore the geography column from SELECT statements, code works fine, but as soon as the stored procedures also return this column, code stops working. Can it be that DataSet does not know how to treat Geography type data?

Any insight is highly appreciated.


It's very possible. The Geography datatype is one of the built-in CLR datatypes, so I could see that being an issue especially if you're using a version of ADO.NET that isn't aware of it.

0

上一篇:

下一篇:

精彩评论

暂无评论...
验证码 换一张
取 消

最新问答

问答排行榜