4 lines
206 B
SQL
4 lines
206 B
SQL
ALTER TABLE posts
|
|
ADD COLUMN tsvector_content tsvector GENERATED ALWAYS AS (to_tsvector ('english', coalesce(content, ''))) STORED;
|
|
|
|
CREATE INDEX tsvector_content_idx ON posts USING GIN (tsvector_content);
|