Subject query optimizing
Author Bram
With the help from the ibobjects lists I created a database/table with about 450.000 records with all street names in the Netherlands.
 
CREATE TABLE "POSTCODE"
(
       "ID"      INT64         NOT NULL,
   "STREET"       CHAR(    50) CHARACTER SET NONE,
     "CITY"       CHAR(    50) CHARACTER SET NONE,
 "POSTCODE"       CHAR(     7) CHARACTER SET NONE,
 CONSTRAINT "PK_POSTCODE" PRIMARY KEY ("ID")
);
 
CREATE ASC INDEX "POSTCODE" ON "POSTCODE" ("POSTCODE");
CREATE ASC INDEX "STREET" ON "POSTCODE" ("STREET");
I created the following query :
 
SELECT STREET FROM POSTCODE WHERE STREET CONTAINING 'BRAM'
 
There are actually 130 streets in Holland containing my first name. But it takes about 10/15 seconds before its returning the 130 rows with an IB_Query set on active. Is there a way to check if the query is 100% optimized.
 
Could it go faster ?
 
Bram van der Voet / A&V Automatisering
Glasbergenlaan 6
2235 BP VALKENBURG ZH
tel 071 407 6956
fax 071 407 3939