select T1.id,T1.ODate,T1.DeliDate,T1.Particulars,T1.Amount,T2.Orderid, Coalesce(sum(T2.paidamount),0) from tbl_Hostels T1 Left Join tbl_HostelPayment T2 on T2.Orderid= T1.id where T1.Billpaid='Cancel' and T1.ODate<='" & Format(DTPFrom.Value, "MM-dd-yyyy") & "' and T1.ODate<='" & Format(DTPTo.Value, "MM-dd-yyyy") & "' order by T1.id "
var
This content, along with any associated source code and files, is licensed under The Code Project Open License (CPOL)