FROM vwCarReservationsforVendorCost
LEFT OUTER JOIN tblVendorPaymentVouchers ON
tblVendorPaymentVouchers.VendorId=vwCarReservationsforVendorCost.VendorId
WHERE (ReservedDate >= @OrderDateFrom OR @OrderDateFrom = '01/01/1900') AND
(ReservedDate<=@OrderDateTo OR @OrderDateTo='01/01/1900') AND
(vwCarReservationsforVendorCost.vendorId in (SELECT VendorId FROM OPENXML (@iDoc, '/VENDORS/VENDOR',1) WITH (VendorId INT)) OR @Vendors='
GROUP BY vwCarReservationsforVendorCost.VendorId,vwCarReservationsforVendorCost.VendorName
//this is how you enter the parameters from front end
foreach (ListItem item in lbDeliveryService.Items)
{
if (item.Selected)
{
sbVender.AppendFormat("
}
}
sbVender.Append("");
DataSet ds = OBJOrder.SearchVendorDeliverCostAnalysisReports(fromDate, toDate, sbVender.ToString());
No comments:
Post a Comment