Quote:
Originally Posted by Fumigator
Well shoot, there goes my theory.
Can you narrow down where the bottleneck is-- connecting? fetching? Any errors being reported in Apache error log?
|
The problem is with the function odbc_connect. Once the connection resource is available everything works fine.
Script execution time from command line (in milliseconds):
odbc_connect : 754 (0.7 second)
odbc_prepare : 104
odbc_execute : 80
odbc_fetch_object : 3
odbc_fetch_object : 0
odbc_fetch_object : 1
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 1
odbc_fetch_object : 0
Script execution time from Apache (in milliseconds):
odbc_connect : 127125 (127.125 seconds)
odbc_prepare : 94
odbc_execute : 96
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 1
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
odbc_fetch_object : 0
Remember that both executions where done in the same server and the DB2 server is a remote server.