Where clause...

Поиск
Список
Период
Сортировка
От Didier Gasser-Morlay
Тема Where clause...
Дата
Msg-id 608b66ce0802030026h57f54c8fg43c459743d59e234@mail.gmail.com
обсуждение исходный текст
Ответы Re: Where clause...  ("A. Kretschmer" <andreas.kretschmer@schollglas.com>)
Список pgsql-novice
Hello,

I have a table which a column "fee_type " declared as char(1)

The column can contain 'I' (uppercase i), 'C' or 'R'

When querying with Select * from <table> where fee_type in ('I', 'C')

the query returns nothing.

The query returns the rows I am expecting when doing one of the following:

where fee_type ilike ('I') or fee_type ilike ('C')
or
where fe.fee_type = chr(73) or fee_type = chr(67)
(this proves the value is indeed uppercase)

but nothing is returned either when I try
where fee_type like ('I') or fee_type like ('C')

I thought it would be related to the datatype so I tried casting the
'I' and 'C' to char(1), but I had no luck.

Could you give me a hint ?

thanks
Didier

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

Предыдущее
От: Raimon
Дата:
Сообщение: Re: Multiple rows into one row
Следующее
От: "A. Kretschmer"
Дата:
Сообщение: Re: Where clause...