SELECT CONVERT (nvarchar(10),CHECKTIME,103) As Date_Conv, CONVERT (nvarchar(10),CHECKTIME,108) As Time_Conv, * FROM V_LogAllUser WHERE CHECKTIME BETWEEN '" & StrDate & "' AND '" & EndDate & "';
แล้วพอรันจะ Error แบบนี้ครับ
The conversion of a varchar data type to a datetime data type resulted in an out-of-range value.
SELECT CONVERT (nvarchar(10),CHECKTIME,103) As Date_Conv, CONVERT (nvarchar(10),CHECKTIME,108) As Time_Conv, * FROM V_LogAllUser WHERE CHECKTIME BETWEEN '" & StrDate & "' AND '" & EndDate & "';