| От | Tom Lane |
|---|---|
| Тема | Re: bug with distinct? |
| Дата | |
| Msg-id | 12736.981768203@sss.pgh.pa.us обсуждение исходный текст |
| Ответ на | bug with distinct? (Alfonso Peniche <alfonso@iteso.mx>) |
| Ответы |
Re: bug with distinct?
|
| Список | pgsql-general |
Alfonso Peniche <alfonso@iteso.mx> writes:
> SELECT distinct 'mod_type' ,currval('mytable_idmytable_seq') from
> mytable;
> ERROR: Unable to identify an ordering operator '<' for type 'unknown'
> Use an explicit ordering operator or modify the query
You need to give the literal an explicit type, eg,
SELECT distinct 'mod_type'::text, currval('mytable_idmytable_seq') from
mytable;
7.1 will default to assuming that you meant 'text' in this scenario,
but older releases are pickier.
regards, tom lane
В списке pgsql-general по дате отправления:
Сайт использует файлы cookie для корректной работы и повышения удобства. Нажимая кнопку «Принять» или продолжая пользоваться сайтом, вы соглашаетесь на их использование в соответствии с Политикой в отношении обработки cookie ООО «ППГ», в том числе на передачу данных из файлов cookie сторонним статистическим и рекламным службам. Вы можете управлять настройками cookie через параметры вашего браузера