Re: Re Query Taking Too Long
Posted in 1996
This is a multi-part message in MIME format. --------------5C1842B377D5 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Billy Wheeler wrote: > > At 11:34 AM 3/11/96 -0500, Peter Wages wrote: > > General question. Since it is relatively fast to make an index. In > >this case a half hour. Can't informix automatically make an index > >when it is optimizing a query? A temporary index for example? > > Uh, I think, uh, if Informix creates a temp table it'll index it if needed. > I dunno about temp indexes on "real" tables. Generally speaking, the same rules that apply to accessing a permanent table will apply to accessing a temporary table. In answer to Peter's question, yes we can create an index for the query. It has been around since the earliest days of Informix SQL products, and is known as auto-indexing. However, consider that an auto-index only persists for the life of the query, and then is dropped. For a one-time query, this would not be bad, but for a query or queries run with any regularity, the overhead of building that index every time makes it rather unpalatible. Furthermore, with the introduction of hash joins in 7.X, we have a much better solution. A hash table is faster to build, faster to access, and uses fewer resources in the process. I don't think you will see many auto-indexes being built anymore. -- Dave Kosenko, Informix Professional Services **************************************************************************** While it is true that there is more than one way to skin a cat, the cat himself generally fails to appreciate the differences. --------------5C1842B377D5 Content-Type: text/plain; charset=us-ascii Content-Transfer-Encoding: 7bit Content-Disposition: inline; filename="IFXDISCL.TXT" ************************************************************************* Note: please do not send me email asking about features, or asking about Informix problems and how to solve them. I answer what questions I can in this forum (comp.databases.informix) when I have the time to spare. For questions on features, call your local sales rep or check out the Informix web site (http://www.informix.com). For technical problems, call Informix tech support. ************************************************************************* Disclaimer: All opinions expressed in this message are well-reasoned and insightful; needless to say, they are not those of Informix Software, its partners or lackeys. Anyone who says otherwise is itching for a fight. --------------5C1842B377D5--