Hello, Just small question about postgres query optimizer. If I have a table with 2 fields a and b. I have indices for both of them. Table is quite large (> 100000). I do: select * from q where a = 10 and b = 20; I know that the best solution is to build the index on both columns, but... Will postgres consider to use one of the indices to make initial cut? This should be quite useful... One example where this will be useful is: we have a query where one of the conditions is very restrivtive and index can be used on it, another condition is complicated functional one. If we use index on the first column and calculate all others this will be much faster than sequence scan. Any thoughts? -- Sincerely Yours, Denis Perchine ---------------------------------- E-Mail: dyp@perchine.com HomePage: http://www.perchine.com/dyp/ FidoNet: 2:5000/120.5 ----------------------------------
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера