I am having a lot of trouble with these three. When I try to have a WHERE clause which include [tt]'someDate > 04/01/2003'[/tt] it brings up ALL of the records. If I have WHERE clause which includes [tt]'someDate < 04/01/2003'[/tt] it brings NONE of the records. On both of the clauses it should bring up about half of the records.
Below is the test ASP code that I am using to get this to work.
[tt]
<%
Set bookRS = Server.CreateObject("ADODB.recordset"
Set bookConn = Server.CreateObject("ADODB.Connection"
bookConn.open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & server.mappath("db\cpRental.mdb"
& ";"
strSQL = "SELECT bookingID FROM booking WHERE bookingStatus = 'book' AND bookingFinish < 01/05/2003"
bookRS.Open strSQL, bookConn
i = 0
Do While not bookRS.EOF
i = i + 1
response.write (i & ": " & bookRS("bookingID"
& "<br>"
bookRS.MoveNext
loop
bookRS.Close
bookConn.close
set bookConn=Nothing
set bookRS=Nothing
%>
[/tt]
If anyone can help it would be much appreciated. I am using IIS for the ASP, but I am not too sure for the SQL server. It is being run on Win 2000 Server.
Thanking you in advance
Rick
Below is the test ASP code that I am using to get this to work.
[tt]
<%
Set bookRS = Server.CreateObject("ADODB.recordset"
Set bookConn = Server.CreateObject("ADODB.Connection"
bookConn.open "Provider=Microsoft.Jet.OLEDB.4.0;Data Source=" & server.mappath("db\cpRental.mdb"
strSQL = "SELECT bookingID FROM booking WHERE bookingStatus = 'book' AND bookingFinish < 01/05/2003"
bookRS.Open strSQL, bookConn
i = 0
Do While not bookRS.EOF
i = i + 1
response.write (i & ": " & bookRS("bookingID"
bookRS.MoveNext
loop
bookRS.Close
bookConn.close
set bookConn=Nothing
set bookRS=Nothing
%>
[/tt]
If anyone can help it would be much appreciated. I am using IIS for the ASP, but I am not too sure for the SQL server. It is being run on Win 2000 Server.
Thanking you in advance
Rick