types & index usage

Поиск
Список
Период
Сортировка
От Timur Irmatov
Тема types & index usage
Дата
Msg-id 746750156.20030123131425@sarkor.com
обсуждение исходный текст
Список pgsql-general
Hi!

I have a table with year, month, day and hour fields (all SMALLINT
type).  Selecting one row from it takes about 40 msecs, and I am
trying now to use DATE type instead of first three fields.

Now select time decreased to less than millisecond, but I found that i
must use this form: hour=10::smallint instead of simple hour=10,
because in the latter case PostgreSQL does sequential scan.

I've heard something about type coercion issues, so I just want to say
that it is very funny to see such sort of things...


В списке pgsql-general по дате отправления:

Предыдущее
От: "Ivar"
Дата:
Сообщение: ??? Multiple selects in procedure
Следующее
От: "codeWarrior"
Дата:
Сообщение: Re: agregates