Igor
2007-06-06 18:50:25 UTC
I use following code on asp.net page to retrieve indexing server data:
Dim da As New OleDbDataAdapter
rsQuery = objQuery.CreateRecordset("nonsequential")
da.Fill(ds, rsQuery, "ISResults")
And occasionally it throws following error:
Object reference not set to an instance of an object.
at System.Data.Common.IRowset.GetData(IntPtr hRow, IntPtr
hAccessor, HandleRef pData)
at System.Data.OleDb.OleDbDataReader.GetRowDataFromHandle()
at System.Data.OleDb.OleDbDataReader.FindValueBinding(Int32 index)
at System.Data.OleDb.OleDbDataReader.PeekValueBinding(Int32 index)
at System.Data.OleDb.OleDbDataReader.GetValues(Object[] values)
at System.Data.Common.SchemaMapping.LoadDataRow(Boolean
clearDataValues, Boolean acceptChanges)
at System.Data.Common.DbDataAdapter.FillLoadDataRow(SchemaMapping
mapping)
at System.Data.Common.DbDataAdapter.FillFromReader(Object data,
String srcTable, IDataReader dataReader, Int32 startRecord, Int32
maxRecords, DataColumn parentChapterColumn, Object parentChapterValue)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String
srcTable, IDataReader dataReader, Int32 startRecord, Int32 maxRecords)
at System.Data.OleDb.OleDbDataAdapter.FillFromRecordset(Object
data, ADORecordsetConstruction recordset, String srcTable, Boolean&
incrementResultCount)
at System.Data.OleDb.OleDbDataAdapter.FillFromADODB(Object data,
Object adodb, String srcTable, Boolean multipleResults)
at System.Data.OleDb.OleDbDataAdapter.Fill(DataSet dataSet, Object
ADODBRecordSet, String srcTable)
Any thoughts how it could be fixed?
Dim da As New OleDbDataAdapter
rsQuery = objQuery.CreateRecordset("nonsequential")
da.Fill(ds, rsQuery, "ISResults")
And occasionally it throws following error:
Object reference not set to an instance of an object.
at System.Data.Common.IRowset.GetData(IntPtr hRow, IntPtr
hAccessor, HandleRef pData)
at System.Data.OleDb.OleDbDataReader.GetRowDataFromHandle()
at System.Data.OleDb.OleDbDataReader.FindValueBinding(Int32 index)
at System.Data.OleDb.OleDbDataReader.PeekValueBinding(Int32 index)
at System.Data.OleDb.OleDbDataReader.GetValues(Object[] values)
at System.Data.Common.SchemaMapping.LoadDataRow(Boolean
clearDataValues, Boolean acceptChanges)
at System.Data.Common.DbDataAdapter.FillLoadDataRow(SchemaMapping
mapping)
at System.Data.Common.DbDataAdapter.FillFromReader(Object data,
String srcTable, IDataReader dataReader, Int32 startRecord, Int32
maxRecords, DataColumn parentChapterColumn, Object parentChapterValue)
at System.Data.Common.DbDataAdapter.Fill(DataSet dataSet, String
srcTable, IDataReader dataReader, Int32 startRecord, Int32 maxRecords)
at System.Data.OleDb.OleDbDataAdapter.FillFromRecordset(Object
data, ADORecordsetConstruction recordset, String srcTable, Boolean&
incrementResultCount)
at System.Data.OleDb.OleDbDataAdapter.FillFromADODB(Object data,
Object adodb, String srcTable, Boolean multipleResults)
at System.Data.OleDb.OleDbDataAdapter.Fill(DataSet dataSet, Object
ADODBRecordSet, String srcTable)
Any thoughts how it could be fixed?