0
create proc splist_of_current_orders (@fromdate nvarchar(50),@todate nvarchar(50))
as
begin
SELECT
ot.Order_Id,
ot.Pay_date,
ot.Pay_type,
ot.Merchant_Id,
t.BusinessName,
t.OyospaName,
tu.Userfullname,
ot.Booked_Date
FROM dbo.Tbl_Order_Trans AS ot
LEFT OUTER JOIN
dbo.Tbl_ServiceCategory AS sc ON sc.ServiceCategoryID = ot.ServiceCategoryID
LEFT OUTER JOIN
dbo.Tbl_user AS tu ON ot.UserId = tu.UserId
LEFT OUTER JOIN
dbo.Tbl_Merchant AS t ON ot.Merchant_Id = t.Merchant_Id
where ot.Booking_Date BETWEEN @fromdate and @todate
end