Configuring pg_textsearch

pg_textsearch isn't relocatable. You must add it to shared_preload_libraries and restart the server before you can create the extension.

  1. Add pg_textsearch to the shared_preload_libraries parameter, either in postgresql.conf or with ALTER SYSTEM:

    ALTER SYSTEM SET shared_preload_libraries = 'pg_textsearch';

    If shared_preload_libraries already lists other extensions, append pg_textsearch to the list rather than overwriting it. The order doesn't matter.

  2. Restart Postgres for the change to take effect.

  3. Create the pg_textsearch extension in your database:

    CREATE EXTENSION pg_textsearch;
  4. Confirm the extension is installed:

    SELECT extname, extversion FROM pg_extension WHERE extname = 'pg_textsearch';

Could this page be better? Report a problem or suggest an addition!