Subject Re: [IBO] skip metadata to increase remote speed?
Author hkuser2001
--- In IBObjects@y..., Helen Borrie <helebor@t...> wrote:
> At 01:17 PM 28-11-02 +0000, you wrote:
>
> [snip]
>
> However, if you are getting a query on the system tables before a
query
> opens the first time, it looks as if you have GetServerDefaults set
> true...this will slow down your query, for sure. I *never* use
it. IBO
> allows you to inform your connection object of all of the defaults
for all
> tables. I do it that way. I don't want to waste bandwidth getting
> defaults for a query the user may not intend to update.
>
> There is certainly something going on there to slow things down. It
> shouldn't take 5 seconds to do the GetServerDefaults query...unless
you
> have some very huge values assigned as defaults, of course.
>
> Now that we know you have the monitor running, how about posting a
clip
> from the output, showing the plan for your slow query?
>
> Helen

Dear Helen,

Thanks for your quick response.

1. The GetServerDefaults was never enabled. There is no huge values
assigned as defaults.

2. The plan for the "slow" query running on Remote is here:
/*---
PREPARE STATEMENT
TR_HANDLE = 4150092
STMT_HANDLE = 4149900

SELECT ID, NAME FROM BRAND

PLAN (BRAND NATURAL)

FIELDS = [ Version 1 SQLd 2 SQLn 30
BRAND.ID = <NIL>
BRAND.NAME = <NIL> ]

SECONDS = 5.875
----*/

3. The plan for the "slow" query running on Local network is here:
/*---
PREPARE STATEMENT
TR_HANDLE = 4150760
STMT_HANDLE = 4150568

SELECT ID, NAME from brand;

PLAN (BRAND NATURAL)

FIELDS = [ Version 1 SQLd 2 SQLn 30
BRAND.ID = <NIL>
BRAND.NAME = <NIL> ]

SECONDS = 0.040
----*/


You can see the dramatic delay in remote situation.
The returned result set is very simple:
ID NAME
============ ====================
1 AMD
2 INTEL
3 MOTOROLA
4 FAIRCHILD
6 SANYO

I guess the prepare stage involve a lot of traffic, am I right?
Is there anything I can do to eliminate it?

Rgds,
Michael