Thread: could not determine which collation to use for string comparison

could not determine which collation to use for string comparison

From
Andrey
Date:
Hello.
PostgreSQL 9.6.2 on x86_64-pc-linux-gnu, compiled by gcc (Debian 4.9.2-10) 4.9.2, 64-bit

select *
from (select 'test'::text collate "C" id) c1
full join (select 'test'::text collate "en_US" id) c2 on 
-- c1.id = c2.id  ----< ok
c1 = c2

ERROR: could not determine which collation to use for string comparison
SQLSTATE: 42P22

Records comparison does not work if corresponding fields have different collation.