select tblSalesTransaction.date,tblSalesTransaction.inv from tblSalesTransaction where CAST(tblSalesTransaction.date AS Date) between CAST('" + dtpFrom.Value + "' AS DAte) and CAST('" + dtpTo.Value + "', as Date)"
select tblSalesTransaction.date,tblSalesTransaction.inv from tblSalesTransaction where dateadd(dd,0, datediff(dd,0, tblSalesTransaction)) between dateadd(dd,0, datediff(dd,0, " + dtpFrom.Value + " )) AND dateadd(dd,0, datediff(dd,0, " + dtpTo.Value + " )) "