SiteCode | date |softwarename | Success | Error
ASZ 2017-08-5 a 1 1
ASZ 2017-08-5 b 2 2
ASZ 2017-08-5 a 3 3
ASZ 2017-08-6 a 6 6
NBL 2017-08-5 a 5 5
var CurrentCustomer = Database.Session.Query<Customer>()
.FirstOrDefault(x => x.deleted_at == null
&& x.Customer_Username == User.Identity.Name);
if(CurrentCustomer != null)
{
var CurrentDepValues = Database.Session.Query<deployments>()
.Where(x => x.SiteCode == CurrentCustomer.SiteCode
&& x.softwarename == current_type)
.OrderBy(x => x.date)
.ToList();
}
I have a db like that. I want to get an output like below. The same date values should be sum.
SiteCode | date |softwarename | Success | Error
ASZ 2017-08-5 a 4 4
ASZ 2017-08-6 a 6 6