How to compare previous record column value with current record column value in c# linq

Posted by Kasani007 under LINQ on 2/15/2018 | Points: 10 | Views : 467 | Status : [Member] | Replies : 1
compare previous record column value with current record column value in c# linq

my linq query is as below :

 var list = (from v in db.VehicleLocation
where v.VehicleId == vehicleId
select new VehicleLocationModel
{
Id = v.Id,
Location = v.Location,
DateTimestamp = v.DateTimestamp,
DiffTimestamp = v.DateTimestamp - previoustimestamp
}).OrderBy(x => x.DateTimestamp).ToList();


please help me...




Responses

Posted by: Mspaintsupport on: 2/17/2018 [Member] Starter | Points: 25

Up
0
Down
Thanks for such a nice information if you want to get help in MS Paint while using it the contact us at https://disqus.com/by/powerpointcustomerservice/

Kasani007, if this helps please login to Mark As Answer. | Alert Moderator

Login to post response