hi list
i got a weird problem. somehow, for pg-sql, this statement is not true:
SELECT lower('zwiebelbäcker') = 'zwiebelbäcker'
=> false (which is the wrong answer, obviously)
amazingly, this one works fine:
SELECT lower('zwiebelbacker') = 'zwiebelbacker'
=> true
thus, the following query fails:
SELECT login FROM users.users WHERE lower(login) = 'zwiebelbäcker'
=> 0 Result (not correct!!)
workaround:
SELECT login FROM users.users WHERE lower(login) = lower('zwiebelbäcker')
=> 1 Result (correct)
why is this and how can it be circumvented? my workaround of using lower()
only works as so long as i don't want case-insensitive checks... i've
already tried to cast it to text by using ::text, didn't help.
thanks,
thomas