I've just started writig some simple web scripts to access data that is stored in an Informix database, version 7.24. I'm accessing this from PHP via an Apache 2 module on Windows XP. The problem is that there is a long delay in performing some operations. For example, I have a script that does the following:

1. Connect to ODBC.
2. Send query.
3. Fetch result.

Up to stage 2 everything works fine, but on stage 3, the call to odbc_fetch_array takes a minimum of 20 seconds to return. I have hunted about on the web for a possible solution, but nothing came up. Does anyone on here have any idea? I have seen that this may be due to a slow connection caused by name resolution issues, but I'm not sure if this is the same thing as I am experiencing.