Subject Re: [IBO] IBO Question
Author Michael Vilhelmsen
>
> How long does it take to open again, if you close it and reopen it?
INSTANTLY !!

> Put a monitor on and watch to see what is taking the time. (drop a
> TIB_MonitorDialog on the form and call its Show method in your
FormCreate).

This is the result.
Lines of my memo has been cleared just before open.
and they are save right after open.
But I don't know what I shall look for !


/*---
DATABASE INFO
DB_HANDLE = 3838972

SECONDS = 0,010
----*/
/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3838784
----*/
/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3838328
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3838328
STMT_HANDLE = 3838400

SELECT RDB$PROCEDURE_NAME
FROM RDB$PROCEDURES
ORDER BY RDB$PROCEDURE_NAME ASC

PLAN (RDB$PROCEDURES ORDER RDB$INDEX_21)

FIELDS = [ Version 1 SQLd 1 SQLn 30
RDB$PROCEDURES.RDB$PROCEDURE_NAME = <NIL> ]

SECONDS = 0,250
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3838328
STMT_HANDLE = 3838400
PARAMS = [ ]

SECONDS = 0,010
----*/
/*---
COMMIT
TR_HANDLE = 3838328
----*/
/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3832892
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3832892
STMT_HANDLE = 3838400

SELECT S.RDB$FIELD_NAME
, I.RDB$RELATION_NAME
FROM RDB$RELATION_CONSTRAINTS C
, RDB$INDICES I
, RDB$INDEX_SEGMENTS S
WHERE C.RDB$CONSTRAINT_TYPE = 'PRIMARY KEY'
AND C.RDB$RELATION_NAME = I.RDB$RELATION_NAME
AND C.RDB$INDEX_NAME = I.RDB$INDEX_NAME
AND I.RDB$INDEX_NAME = S.RDB$INDEX_NAME
ORDER BY I.RDB$RELATION_NAME ASC
, S.RDB$FIELD_POSITION ASC

PLAN SORT (JOIN (C NATURAL,I INDEX (RDB$INDEX_5,RDB$INDEX_31),S INDEX
(RDB$INDEX_6)))

FIELDS = [ Version 1 SQLd 2 SQLn 30
RDB$INDEX_SEGMENTS.RDB$FIELD_NAME = <NIL>
RDB$INDICES.RDB$RELATION_NAME = <NIL> ]

SECONDS = 0,020
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3832892
STMT_HANDLE = 3838400
PARAMS = [ ]

SECONDS = 0,040
----*/
/*---
COMMIT
TR_HANDLE = 3832892
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3838784
STMT_HANDLE = 3838592

Select * from Bon_Master

PLAN (BON_MASTER NATURAL)

FIELDS = [ Version 1 SQLd 26 SQLn 30
BON_MASTER.BONNR = <NIL>
BON_MASTER.ART = <NIL>
BON_MASTER.BONSTATUS = <NIL>
BON_MASTER.ANNULLERET = <NIL>
BON_MASTER.BUTIK = <NIL>
BON_MASTER.KASSE = <NIL>
BON_MASTER.DATO_TRANS = <NIL>
BON_MASTER.DATO = <NIL>
BON_MASTER.TID = <NIL>
BON_MASTER.EKSPEDIENT = <NIL>
BON_MASTER.EKSPEDIENT_NR = <NIL>
BON_MASTER.DEBITOR_NR = <NIL>
BON_MASTER.NAVN = <NIL>
BON_MASTER.ADRESSE = <NIL>
BON_MASTER.POSTNR = <NIL>
BON_MASTER.BY_ = <NIL>
BON_MASTER.LAND = <NIL>
BON_MASTER.TLF = <NIL>
BON_MASTER.FAX = <NIL>
BON_MASTER.WEB = <NIL>
BON_MASTER.EMAIL = <NIL>
BON_MASTER.EKSBONTEXT = <NIL>
BON_MASTER.AFDELING_ID = <NIL>
BON_MASTER.UAFD_NAVN = <NIL>
BON_MASTER.UAFD_GRP_NAVN = <NIL>
BON_MASTER.ID = <NIL> ]

SECONDS = 0,020
----*/
/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3832956
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3832956
STMT_HANDLE = 3838400

SELECT R.RDB$FIELD_NAME
, R.RDB$RELATION_NAME
FROM RDB$RELATION_FIELDS R, RDB$FIELDS F
WHERE R.RDB$FIELD_SOURCE = F.RDB$FIELD_NAME
AND F.RDB$COMPUTED_SOURCE IS NOT NULL
AND NOT R.RDB$RELATION_NAME STARTING WITH 'RDB$'
ORDER BY 1 ASC

PLAN SORT (JOIN (F NATURAL,R INDEX (RDB$INDEX_3)))

FIELDS = [ Version 1 SQLd 2 SQLn 30
RDB$RELATION_FIELDS.RDB$FIELD_NAME = <NIL>
RDB$RELATION_FIELDS.RDB$RELATION_NAME = <NIL> ]

SECONDS = 0,020
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3832956
STMT_HANDLE = 3838400
PARAMS = [ ]

SECONDS = 0,041
----*/
/*---
COMMIT
TR_HANDLE = 3832956
----*/
/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3832984

SECONDS = 0,010
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3832984
STMT_HANDLE = 3838400

SELECT F.RDB$FIELD_NAME F_FieldName
, F.RDB$RELATION_NAME F_RelationName
, F.RDB$DEFAULT_SOURCE F_DefaultSource
, D.RDB$DEFAULT_SOURCE D_DefaultSource
, D.RDB$FIELD_TYPE D_FieldType
FROM RDB$RELATION_FIELDS F
INNER JOIN RDB$FIELDS D
ON D.RDB$FIELD_NAME = F.RDB$FIELD_SOURCE
WHERE (( F.RDB$DEFAULT_SOURCE IS NOT NULL ) OR ( D.RDB$DEFAULT_SOURCE
IS NOT NULL ))
AND NOT F.RDB$RELATION_NAME STARTING WITH 'RDB$'
ORDER BY 1 ASC

PLAN SORT (JOIN (F NATURAL,D INDEX (RDB$INDEX_2)))

FIELDS = [ Version 1 SQLd 5 SQLn 30
RDB$RELATION_FIELDS.RDB$FIELD_NAME[F_FIELDNAME] = <NIL>
RDB$RELATION_FIELDS.RDB$RELATION_NAME[F_RELATIONNAME] = <NIL>
RDB$RELATION_FIELDS.RDB$DEFAULT_SOURCE[F_DEFAULTSOURCE] = <NIL>
RDB$FIELDS.RDB$DEFAULT_SOURCE[D_DEFAULTSOURCE] = <NIL>
RDB$FIELDS.RDB$FIELD_TYPE[D_FIELDTYPE] = <NIL> ]

SECONDS = 0,010
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3832984
STMT_HANDLE = 3838400
PARAMS = [ ]

SECONDS = 0,390
----*/
/*---
COMMIT
TR_HANDLE = 3832984
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3838784
STMT_HANDLE = 3838592
PARAMS = [ ]
----*/





And the sceond time (i just repeated my procedure twice).


/*---
START TRANSACTION
DB HANDLE COUNT 1
TR_HANDLE = 3838784
----*/
/*---
PREPARE STATEMENT
TR_HANDLE = 3838784
STMT_HANDLE = 3838592

Select * from Bon_Master

PLAN (BON_MASTER NATURAL)

FIELDS = [ Version 1 SQLd 26 SQLn 30
BON_MASTER.BONNR[BONNR] = <NIL>
BON_MASTER.ART[ART] = <NIL>
BON_MASTER.BONSTATUS[BONSTATUS] = <NIL>
BON_MASTER.ANNULLERET[ANNULLERET] = <NIL>
BON_MASTER.BUTIK[BUTIK] = <NIL>
BON_MASTER.KASSE = <NIL>
BON_MASTER.DATO_TRANS = <NIL>
BON_MASTER.DATO = <NIL>
BON_MASTER.TID = <NIL>
BON_MASTER.EKSPEDIENT = <NIL>
BON_MASTER.EKSPEDIENT_NR = <NIL>
BON_MASTER.DEBITOR_NR = <NIL>
BON_MASTER.NAVN = <NIL>
BON_MASTER.ADRESSE = <NIL>
BON_MASTER.POSTNR = <NIL>
BON_MASTER.BY_ = <NIL>
BON_MASTER.LAND = <NIL>
BON_MASTER.TLF = <NIL>
BON_MASTER.FAX = <NIL>
BON_MASTER.WEB = <NIL>
BON_MASTER.EMAIL = <NIL>
BON_MASTER.EKSBONTEXT = <NIL>
BON_MASTER.AFDELING_ID = <NIL>
BON_MASTER.UAFD_NAVN = <NIL>
BON_MASTER.UAFD_GRP_NAVN = <NIL>
BON_MASTER.ID = <NIL> ]
----*/
/*---
EXECUTE STATEMENT
TR_HANDLE = 3838784
STMT_HANDLE = 3838592
PARAMS = [ ]

SECONDS = 0,010
----*/



>
> Also tell us how you are implementing the connection - what do the
Server
> and Path properties look like?
SERVER: Ghost
PATH: /data/delphi/easyposdata/Mini DB/OCCEASYPOS.GDB
DB: Ghost:/data/delphi/easyposdata/Mini DB/OCCEASYPOS.GDB


What is the in DatabaseName path of the
> IBOQuery?

QUERYDBNAME: Database



Michael