aspdotnetstorefront

Intermittent System.IndexOutOfRangeException when reading a field from IDataReader

↘锁芯ラ 提交于 2019-12-07 07:23:36
问题 I have a very weird problem in code that I would not expect to ever fail. It is a website with some traffic but not that huge based on AspDotNetStoreFront. Site intermittently crashes when trying to read a database field from a reader. This happen on various places on the website. An example of such code is below on the line with object pValue = rs["PropertyValueString"]; private Dictionary<string, object> GetPropertValuePairs(string userName) { string query = string.Format("select

Intermittent System.IndexOutOfRangeException when reading a field from IDataReader

那年仲夏 提交于 2019-12-05 17:58:14
I have a very weird problem in code that I would not expect to ever fail. It is a website with some traffic but not that huge based on AspDotNetStoreFront. Site intermittently crashes when trying to read a database field from a reader. This happen on various places on the website. An example of such code is below on the line with object pValue = rs["PropertyValueString"]; private Dictionary<string, object> GetPropertValuePairs(string userName) { string query = string.Format("select PropertyName, PropertyValueString from dbo.profile with(nolock) where CustomerGUID = {0} and StoreID = {1}", DB