Re: Foreign key indexing.
Posted in 1994
In article <9407251226.AA15895@expo.din.lois.perm.su> res@expo.din.lois.perm.su (Igor G. Popov, LOIS Ltd.) writes: > Hello, Informixers! > [...] > This is my question: is it useful to create indexes on each > component of the composite foreign key, if there is a composite > index on the hole key already? > It may be useful to create a single index on several components of your comosite keys. This may be the case when your queries depend on parts of your composite keys. It may be helpful to SET EXPLAIN ON and take a look at the optimizers protocol. You may gain some insight into what the optimizer does, and, in some special cases, you may add (or even drop) indexes from your tables. In general one can't tell whether it helps to add single column indexes where you have complex ones already. Best wishes Heinrich -- =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-= /M/A/I Deutschland GmbH, Softwarezentrum Koeln Heinrich Seebauer Mathias-Brueggen-Str. 85 Software Engineering 50829 Koeln, Federal Republic of Germany Phone: x221/956400-0 Phax: x221/956400-69 emale: heinrich@mai.de =-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=-=