|
|
Choosing A Webhost: |
Re: Тормоза в запросе (ручное планирование): msg#01204db.firebird.russian
Hello, Дмитрий! Дмитрий Студинский wrote: > where ((FTI.Files_Type between 100000 and 199999) > or (FTI.Files_Type between 300000 and 399999)) > > При этом строится план (Имя индекса = IX_ИмяТаблицы_ИмяПоля) > PLAN JOIN (F NATURAL,FP INDEX (IX_FILES_PUBLISHER_file_id),FTI INDEX > (IX_FILES_TYPE_ID_file_id,IX_FILES_TYPE_ID_files_type,IX_FILES_TYPE_ID_files_type)) оптимизатор из-за OR взял IX_FILES_TYPE_ID_files_type два раза, должен выбрать множества ключей и слить их по OR. Если > Прописываю план > PLAN JOIN (F NATURAL,FP INDEX (IX_FILES_PUBLISHER_file_id),FTI INDEX > (IX_FILES_TYPE_ID_file_id)) > > Полная выборка занимает 2сек то получается, что именно оно и виновато. > Пока что в условиях прописал FTI.Files_Type + 1. Но хотелось бы услышать > почему сервак так начинает мучаться? Может вообще удалить ненужные индексы? > > ЗЫ Версия сервера 1.5.3.4870 > Статистика по индексам это если ты недавно set statistics index делал. > IX_FILES_TYPE_ID_files_type = 0,011494252830744 не фонтан. IBAnalyst тебе лучше скажет, нормальный это индекс или нет. В целом нет, особенно если в between много ключей попадает, да еще и по or. Так что ты +0 правильно сделал. -- Dmitri Kuzmenko, www.ibase.ru, (495) 953-13-34
|
|
| <Prev in Thread] | Current Thread | [Next in Thread> |
|---|---|---|
| Previous by Date: | Тормоза в запросе (ручное планирование), Дмитрий Студинский |
|---|---|
| Next by Date: | Интересный эффект на свежезалитых таблицах, Ded |
| Previous by Thread: | Тормоза в запросе (ручное планирование), Дмитрий Студинский |
| Next by Thread: | Интересный эффект на свежезалитых таблицах, Ded |
| Indexes: | [Date] [Thread] [Top] [All Lists] |
Free MagazinesCisco NewsReceive a free quarterly e-newsletter with exclusive articles on how Cisco IT uses its own products and solutions to enable the business. subscribe Systems Management News, the newspaper for IT systems administration and data center managers! Each issue of Systems Management News is chock-full of news and analysis to help you understand what's happening in your field. subscribe The Enterprise Newsweekly eWeek is the essential technology information source for builders of e-business. subscribe Oracle Magazine Oracle Magazine contains technology strategy articles, sample code, tips, Oracle and partner news, how to articles for developers and DBAs, and more. Oracle (NASDAQ: ORCL) is the world's largest enterprise software company. subscribe Total Telecom Total Telecom is "The Economist of the communications industry". subscribe |