RE: Indexing on views?
Posted in 2003
Run the sql with set explain on. The file sqexplain.out will tell you how the optimiser decided to access the tables. That will indicate whether you have the correct indexes. MW > -----Original Message----- > From: owner-informix-list@iiug.org > [mailto:owner-informix-list@iiug.org]On Behalf Of Jay Aymond > Sent: Wednesday, 4 June 2003 12:47 a.m. > To: informix-list@iiug.org > Subject: Re: Indexing on views? > > > Make sure the underlying tables have the correct indexes to > support the > view. > > Can you post a schema of the tables and the view? > > > "Ian Logan" <ian.logan@straker.com> wrote in message > news:bbhvl0$nk6$1@newsg1.svr.pol.co.uk... > > Hi > > > > I am working with 9.21 and Crystal Reports 7. I have > created a view to > base > > the report on but it takes quite a while for the report to > appear. In > > general I have noticed that with views it does seem to take > longer to > access > > the data. The views are normally made up of a main table > with Outer Joins > to > > other reference tables, e.g. a sales table with joins to > customer for name > & > > address, etc. > > > > I think that the lack of performance may be due to problems > with indexing, > > although all the tables are properly indexed in their own > right. As far as > I > > can see their is no way to create an index on a view, but > does anyone have > > any ideas as to how to improve matters? > > > > Many thanks > > Ian Logan > > > > > >