This question is locked. New answers and comments are not allowed.
Running the latest version of ORM. This error occurs on this version and the last version. As you can see, it's a pretty simple query and we loop through each returned value and perform processing - all read access against the ORM. We get the error after several hundred rows are read. It varies from 200 rows to about 600 rows. This tables has 2500 rows total in it. Any ideas where to even begin to look?
using (sc.DAL.CommerceContext context = new DAL.CommerceContext())
{
var address = (from c in context.Customers where ((c.OptedOut == null || c.OptedOut == false) && (c.Email != default(string))) orderby c.CustomerID select new { c.CustomerID, c.Email, c.OptedOut });
foreach (var customer in address)
{
Telerik.OpenAccess.Exceptions.DataStoreException: System.InvalidOperationException: Invalid attempt to read when no data is present. at System.Data.SqlClient.SqlDataReader.ReadColumnHeader(Int32 i) at System.Data.SqlClient.SqlDataReader.IsDBNull(Int32 i) at OpenAccessRuntime.Data.VariableLengthStringConverter.Read(DataHolder& data) at OpenAccessRuntime.Relational.fetch.FopGetProjection.fetch(FetchResult fetchResult, StateContainer stateContainer) at OpenAccessRuntime.Relational.fetch.FetchSpec.createRow(FetchResult fetchResult, StateContainer stateContainer) Processing 1: [0] System.InvalidOperationException: Invalid attempt to read when no data is present. at System.Data.SqlClient.SqlDataReader.ReadColumnHeader(Int32 i) at System.Data.SqlClient.SqlDataReader.IsDBNull(Int32 i) at OpenAccessRuntime.Data.VariableLengthStringConverter.Read(DataHolder& data) at OpenAccessRuntime.Relational.fetch.FopGetProjection.fetch(FetchResult fetchResult, StateContainer stateContainer) at OpenAccessRuntime.Relational.fetch.FetchSpec.createRow(FetchResult fetchResult, StateContainer stateContainer) ---> System.InvalidOperationException: Invalid attempt to read when no data is present. at System.Data.SqlClient.SqlDataReader.ReadColumnHeader(Int32 i) at System.Data.SqlClient.SqlDataReader.IsDBNull(Int32 i) at OpenAccessRuntime.Data.VariableLengthStringConverter.Read(DataHolder& data) at OpenAccessRuntime.Relational.fetch.FopGetProjection.fetch(FetchResult fetchResult, StateContainer stateContainer) at OpenAccessRuntime.Relational.fetch.FetchSpec.createRow(FetchResult fetchResult, StateContainer stateContainer) --- End of inner exception stack trace --- at Telerik.OpenAccess.RT.ExceptionWrapper.Throw() at OpenAccessRuntime.storagemanager.logging.LoggingStorageManager.fetchNextQueryResult(ApplicationContext context, RunningQuery runningQuery, Int32 skipAmount) at OpenAccessRuntime.DataObjects.UnsynchronizedPMProxy.getNextQueryResult(QueryResultWrapper aQrs, Int32 skipAmount) at OpenAccessRuntime.DataObjects.ForwardQueryResult.getMoreData(Int32 requestedIndex) at OpenAccessRuntime.DataObjects.ForwardQueryResult.internalGet(Int32 requestedIndex) at OpenAccessRuntime.DataObjects.ForwardQueryResult.get_Item(Int32 indexParam) at Telerik.OpenAccess.RT.ListEnumerator.setCurrent(Int32 _pos) at Telerik.OpenAccess.RT.ListEnumerator.Move(Int32 relative) at Telerik.OpenAccess.Query.TypedEnumerator`1.System.Collections.IEnumerator.MoveNext() at sc.web.Admin.SendEmail._sendEmail_Click(Object sender, EventArgs e)