.net sybase executenonquery exception

▼魔方 西西 提交于 2019-12-11 08:36:09

问题


I am connecting to Sybase DB from my asp.net application using Sybase.Data.ASEClient namespace. With the recent production release of the App, we included a code in the DatabaseHelper class which just tries to do an ExecuteNonQuery(). In production the line that says command.ExecuteNonQuery(), was throwing an exception that says

"Attempted to read or write protected memory. This is often an indication that other memory is corrupt."

But this does not happen consistently. The application works fine for 4 days and in the fifth day we are suddenly getting this error for a user and then no one else was able to use the application when trying to use the functionality that involved database access.

I also googled and came to know that Sybase.Data.ASEClient has some memory leak issues. But no information on whether it got fixed or not.

Can anyone throw some light on this? have you experienced such issues in your previous projects? And is there a way to figure out the problem by any means?


回答1:


It certainly sounds like a bug in the Sybase driver.

I would try to get support from Sybase and/or a more recent version of the driver. Google isn't as helpful as it could be for Sybase support, as I believe you need to be registered to access this kind of info on the Sybase website.

As for memory leaks, I remember that in the past (2006) the Sybase driver 1.1.465.0 had memory leaks - this was fixed in 1.1.516.0. These were drivers for Sybase 12 and things have of course evolved a long way since then.



来源:https://stackoverflow.com/questions/5321370/net-sybase-executenonquery-exception

易学教程内所有资源均来自网络或用户发布的内容,如有违反法律规定的内容欢迎反馈
该文章没有解决你所遇到的问题?点击提问,说说你的问题,让更多的人一起探讨吧!