Forums > Server-Side Scripting
Subject: Passing date variable from form
| Posted By | ||
|---|---|---|
| robx1971 Thu 5th Oct '09 21:33 user |
I am trying to search a date range but I am having problems with the SQL statement:
There is only one date field in the table (logDate) and the form has a startDate (text field) and endDate (text field). Using MS SQL 2005, VBScript and Dreamweaver CS4 I get a "Conversion failed when converting datetime from character string" message. ASP CODE: Thanks in advance. |
![]() |
| Rob Mon 2nd Nov '09 18:40 admin |
Couple of questions first...
1. What database are you using? 2. What is the field type of the logDate field? ...you would obviously have to take the type of field into consideration when building your sql script, also, instead of the AND, use the BETWEEN method eg. |
![]() |


