Just in case this hits you too when you use
CITEXT fields that were originally defined in a Postgres before version 9.1.
ProgrammingError: could not determine which collation to use for string comparison
HINT: Use the COLLATE clause to set the collation explicitly.
This can happen if you use something like:
name is a case insensitive text field.
After some googling around and shooting in the dark I found the the only way to crack this is to run this command:
CREATE EXTENSION citext FROM unpackaged;
Hope that helps some poor schmuck with the same problem.
If you have problems applying this to new tables in Postgres 9.1 you might need to run this instead:
CREATE EXTENSION citext WITH SCHEMA public ;
- Secs sell! How I cache my entire pages (server-side) 10 May 2012
- Related by category:
- How to create-react-app with Docker 17 November 2017 Web development
Fastest way to find out if a file exists in S3 (with boto3) 16 June 2017 Web development
- How to throttle AND debounce an autocomplete input in React 01 March 2018 Web development
- Be very careful with your add_header in Nginx! You might make your site insecure 11 February 2018 Web development
- Displaying fetch() errors and unwanted responses in React 06 February 2019 Web development
- Related by keyword:
- When Docker is too slow, use your host 11 January 2018
- Connecting with psycopg2 without a username and password 24 February 2011
- Adding a year in PostgreSQL 04 February 2004
- How I performance test PostgreSQL locally on macOS 10 December 2018
- Integer division in programming languages 04 August 2004