Discussion:
TIBDataSet.Open slow to return
(too old to reply)
M
2006-09-07 07:07:17 UTC
Permalink
I'm having a problem with a TIBDataSet. When I call Open() it takes around 4
seconds to return when the form it's on is instantiated for the first time.
I don't think it's a problem with the SQL itself because I can run the query in
EMS IBManager and it only takes around 200ms.

If I step through Open() I pass through the following functions:
TDataSet.Open
TIBCustomDataSet.SetActive
TDataSet.SetActive
TDataSet.OpenCursor
TDataSet.DoInternalOpen
TDataSet.UpdateBufferCount
TDataSet.SetBufferCount
TDataSet.GetNextRecords
TDataSet.GetNextRecord
TDataSet.GetBuffer
TIBCustomDataSet.GetRecord
TIBCustomDataSet.InternalGetRecord
TIBSQL.Next
TIBXSQLDA.GetXSQLDA
TIBSQL.GetDatabase
TIBSQL.GetSQLDialect
StatusVector

At this point when I step past the end of StatusVector (I'm not sure what unit
it's in) it takes around 3 seconds until the debugger finally rests on the first
line of TIBSQL.Call.

Any subsequent calls to open for that TIBDataSet only take a few hundred ms to
return while the program is still open. Once I close and reopen the program the
problem starts all over again.

Does anyone know what could be going on?

Running BCB6 pro 10.166.

TIA
Quinn Wildman
2006-09-07 15:25:15 UTC
Permalink
How many rows are you returning?
Post by M
I'm having a problem with a TIBDataSet. When I call Open() it takes
around 4 seconds to return when the form it's on is instantiated for the
first time.
I don't think it's a problem with the SQL itself because I can run the
query in EMS IBManager and it only takes around 200ms.
TDataSet.Open
TIBCustomDataSet.SetActive
TDataSet.SetActive
TDataSet.OpenCursor
TDataSet.DoInternalOpen
TDataSet.UpdateBufferCount
TDataSet.SetBufferCount
TDataSet.GetNextRecords
TDataSet.GetNextRecord
TDataSet.GetBuffer
TIBCustomDataSet.GetRecord
TIBCustomDataSet.InternalGetRecord
TIBSQL.Next
TIBXSQLDA.GetXSQLDA
TIBSQL.GetDatabase
TIBSQL.GetSQLDialect
StatusVector
At this point when I step past the end of StatusVector (I'm not sure
what unit it's in) it takes around 3 seconds until the debugger finally
rests on the first line of TIBSQL.Call.
Any subsequent calls to open for that TIBDataSet only take a few hundred
ms to return while the program is still open. Once I close and reopen
the program the problem starts all over again.
Does anyone know what could be going on?
Running BCB6 pro 10.166.
TIA
M
2006-09-12 21:59:38 UTC
Permalink
any ideas?
Post by Quinn Wildman
How many rows are you returning?
Post by M
I'm having a problem with a TIBDataSet. When I call Open() it takes
around 4 seconds to return when the form it's on is instantiated for
the first time.
I don't think it's a problem with the SQL itself because I can run the
query in EMS IBManager and it only takes around 200ms.
TDataSet.Open
TIBCustomDataSet.SetActive
TDataSet.SetActive
TDataSet.OpenCursor
TDataSet.DoInternalOpen
TDataSet.UpdateBufferCount
TDataSet.SetBufferCount
TDataSet.GetNextRecords
TDataSet.GetNextRecord
TDataSet.GetBuffer
TIBCustomDataSet.GetRecord
TIBCustomDataSet.InternalGetRecord
TIBSQL.Next
TIBXSQLDA.GetXSQLDA
TIBSQL.GetDatabase
TIBSQL.GetSQLDialect
StatusVector
At this point when I step past the end of StatusVector (I'm not sure
what unit it's in) it takes around 3 seconds until the debugger
finally rests on the first line of TIBSQL.Call.
Any subsequent calls to open for that TIBDataSet only take a few
hundred ms to return while the program is still open. Once I close and
reopen the program the problem starts all over again.
Does anyone know what could be going on?
Running BCB6 pro 10.166.
TIA
Loading...