Forum Moderators: open
The application is a job match which serves approx. 10000 users. The users and the jobads are located in a a SQL database.
Whenever I try to fetch the users and their matching jobads, the application runs for about 90 sec. After that an error is returned and I only get through half of the users.
When I run the same application, connecting to the same databse but from another server and IIS it works just fine. The search and match completes after approx. 3 minutes.
I get different errors. Here is an example
------------------------
ADODB.Command error '800a0cc1'
Item cannot be found in the collection corresponding to the requested name or ordinal.
/admin/JobMatch.asp, line 273
------------------------
Another error
-----------------------
Microsoft OLE DB Provider for SQL Server error '80004005'
[DBNETLIB][ConnectionOpen (Connect()).]SQL Server does not exist or access denied.
/admin/JobMatch.asp, line 259
--------------------------------
What can be the problem?
Function FetchNetAds(UserID, firstDate, lastDate)
'read the new job ads for the user
Dim cmdSQL
Dim rs
Set cmdSQL = CreateObject("ADODB.Command")
Set cmdSQL.ActiveConnection = objConn
cmdSQL.CommandType = 4 'adCmdStoredProc
cmdSQL.CommandText = "MatchMyNetAds"
cmdSQL.Parameters("@UserID") = UserID
cmdSQL.Parameters("@firstDate") = firstDate
cmdSQL.Parameters("@lastDate") = lastDate
'Set rs = Server.CreateObject("ADODB.Recordset")
'rs.CursorLocation = 3
'rs.Open cmdSQL, , 3, 1
'Set FetchNetAds = rs
Set FetchNetAds = cmdSQL.Execute
End Function
-----------------------------------------------