The conversion of a nvarchar data type to a datetime
i have table like this,
table name:transaction_tbl
i have stored procedure like this:
ALTER PROCEDURE [dbo].[Test] @startdate NVARCHAR(100),
@enddate NVARCHAR(100)
AS
BEGIN
SELECT t.PlateNo
FROM Transaction_tbl t
WHERE dtime BETWEEN @startdate + ' 00.01.00.00' AND @enddate + '
23:59.59.00'
END
while executing this i am getting error like this:
The conversion of a nvarchar data type to a datetime data type resulted in
an out-of-range value. i am trying to pass my start date with starting
time and end date with end time of the day,,
No comments:
Post a Comment