index on view
Posted in 1999
Topics: Performance & Tuning, SQL Development & Query Writing
Hi, ALL, Is there any way for Informix 7.3 on UNIX, an index can be created on an view? I am performing a query on the join of two table A and B, the search criteria AC for A table returns a lot of records, and the search criteria BC on B table also returns a lot of records, but the result set which satisfies both AC and BC is very small. So if an index can be created on the view of A join B, I can imaging the performance will be much better than that I have now. Could somebody give a hint? TIA Wendy
Wendy Zheng wrote: > > Hi, ALL, > > Is there any way for Informix 7.3 on UNIX, an index can be created on an > view? > I am performing a query on the join of two table A and B, the search > criteria AC for A table returns a lot of records, > and the search criteria BC on B table also returns a lot of records, but the > result set which satisfies both AC and BC > is very small. So if an index can be created on the view of A join B, I can > imaging the performance will be much > better than that I have now. > Could somebody give a hint? What you are looking for is called a join index and only exists in XPS/DSO. In base IDS and UDO (IDS.2000) you can create a join table, something like the gerunds used to implement many-to-many relationships, that just contains the keys to both tables for all joined records. You will have to maintain the table manually but with an index of its own and made part of the view it will make the view fly. In UDO/IDS.2000 you could build a new index type yourself that implements this. Art S. Kagel