Re: Transforming IN (...) to ORs, volatility

Поиск
Список
Период
Сортировка
От Tom Lane
Тема Re: Transforming IN (...) to ORs, volatility
Дата
Msg-id 4970.1302539702@sss.pgh.pa.us
обсуждение исходный текст
Ответ на Re: Transforming IN (...) to ORs, volatility  (Heikki Linnakangas <heikki.linnakangas@enterprisedb.com>)
Список pgsql-hackers
Heikki Linnakangas <heikki.linnakangas@enterprisedb.com> writes:
> Does anyone object to making BETWEEN and IN more strict about the data 
> types? At the moment, you can do this:

> postgres=# SELECT '1234' BETWEEN '10001'::text AND 10002::int4;
>   ?column?
> ----------
>   t
> (1 row)

> I'm thinking that it should throw an error. Same with IN, if the values 
> in the IN-list can't be coerced to a common type.

You *will* get push-back on that ... maybe from people with badly coded
applications, but I guarantee there will be complaints.
        regards, tom lane


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

Предыдущее
От: "Marc G. Fournier"
Дата:
Сообщение: Re: pgfoundry down?
Следующее
От: Noah Misch
Дата:
Сообщение: Re: switch UNLOGGED to LOGGED