This question is locked. New answers and comments are not allowed.
I am getting the error 'Execution of 'System.Linq.Enumerable:GroupBy(IEnumerable`1,Func`2)' on the database server side currently not implemented.'
when I execute the following query
I tried the query in linqtosql and working fine but I need to use OpenAccess
Is there any solution or workaround this?
when I execute the following query
from t in dbContext.TrackerRecords where t.DeviceSerial.Value.Equals(deviceSerial) && t.Date.Value >= fromDate && t.Date.Value <= toDate orderby t.Date.Value descending group t by t.Date.Value.Date into g select new TripDataModel { Day = g.Key, Trips = (from x in g group x by x.Date.Value.Hour into gj where gj.Max(m => m.Speed.Value) > 0 let AvgSpd = gj.Average(m => m.Speed.Value) select new TripModel { MinSpeed = gj.Min(m => m.Speed.Value), MaxSpeed = gj.Max(m => m.Speed.Value), AvgSpeed = AvgSpd > 0 ? Math.Round(AvgSpd, 2, MidpointRounding.AwayFromZero) : 0, FromHour = new DateTime(g.Key.Year, g.Key.Month, g.Key.Day, gj.Key, 0, 0) }) }I tried the query in linqtosql and working fine but I need to use OpenAccess
Is there any solution or workaround this?