Okay, I'm confused. The code below produces no errors and prints -1
for the RecordCount. I run it on a local Access DB. I ran the query
in Access and it returns correctly one field with one row representing
the Count...
However the Response.Write(numAvailServers) statement prints nothing !
There must be at least one record or it wouldn't go inside the
If....What am I missing here...
'Get number of available servers
strSQLquery = "SELECT COUNT(*) As resF FROM Server "
strSQLquery = strSQLquery & "WHERE server_status=1"
set rs2 = conn.Execute(strSQLquery)
Call ErrorVBScriptReport("Exuecute:" & sqrSQLQuery)
Call ErrorADOReport("Exuecute:" & sqrSQLQuery, conn)
If rs2.EOF = false Then
numAvialServers = rs2.Fields("resF")
Response.Write(numAvailServers)
Response.Write(rs2.RecordCount)
End If