Advertisement

07.25.2008 at 01:05PM PDT, ID: 23596676 | Points: 250
[x]
Attachment Details

ODBC Link from IIS/ASP pages to AS/400 DB2 database lagging. Need to speed it up.

Asked by andrishelp in DB2 Database, Active Server Pages (ASP), AS / 400

Tags: Microsoft / IBM, IIS/ASP/DB2/ ODBC link

We have an intranet running on IIS6 and we are creating some display pages to show current customers contained on our AS/400. We are using an ODBC link to the AS/400. The query must run through about 10,000 records and pull up the customer list for one specific sales person. This query seems to take upwards of 30-60 seconds to run. Seems like it should be able to go through 10,000 recs. a lot faster than that. Is there a better way to do this? I have attached the ASP code we are using.Start Free Trial
1:
2:
3:
4:
5:
6:
7:
8:
9:
10:
11:
12:
13:
14:
15:
16:
17:
18:
19:
20:
21:
22:
23:
24:
25:
set mConn = server.CreateObject("ADODB.Connection")
mConn.Open "DSN=AS400;UID=hiddencode;PWD=hiddencode"
				
mySQL = "SELECT DISTINCT CMBTKY,CMNAME " _			 
      & "FROM   CMP " _
      & "WHERE  (CMDTR = '" & territorynumber & "') " _
      & "AND CMDTMM = '0' " _
      & "ORDER BY CMNAME,CMBTKY "
 
set objRec = server.CreateObject("ADODB.Recordset")
objRec.Open mySQL,mConn,adOpenKeyset,adLockOptimistic
		
    if not objRec.EOF then
 
    do while not objRec.EOF
   
    DISPLAYS RECORDS....
 
    objRec.MoveNext
   
    loop
 
end if
				
objRec.Close
 
Loading Advertisement...
 
[+][-]07.25.2008 at 01:29PM PDT, ID: 22092045

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.25.2008 at 01:39PM PDT, ID: 22092118

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.25.2008 at 01:49PM PDT, ID: 22092189

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
[+][-]07.25.2008 at 01:58PM PDT, ID: 22092254

Often, when Experts are collaborating with members who have asked questions, they will request additional information about the problem. Askers respond with an author comment like this one.

Start your 7-day free trial to view this Author Comment or ask the Experts your question.

 
[+][-]07.25.2008 at 02:08PM PDT, ID: 22092340

At Experts Exchange, members can ask their questions to thousands of technology professionals, also known as Experts. Experts compete and collaborate to answer those questions by leaving comments like this one.

Start your 7-day free trial to view this Expert Comment or ask the Experts your question.

 
 
Loading Advertisement...
20080716-EE-VQP-32 / EE_QW_2_20070628