1 DROP TABLE IF EXISTS word;
4 word_token text NOT NULL,
8 ) {{db.tablespace.search_data}};
10 CREATE INDEX idx_word_word_token ON word
11 USING BTREE (word_token) {{db.tablespace.search_index}};
12 -- Used when updating country names from the boundary relation.
13 CREATE INDEX idx_word_country_names ON word
14 USING btree(word) {{db.tablespace.address_index}}
16 -- Used when inserting new postcodes on updates.
17 CREATE INDEX idx_word_postcodes ON word
18 USING btree(word) {{db.tablespace.address_index}}
20 -- Used when inserting full words.
21 CREATE INDEX idx_word_full_word ON word
22 USING btree(word) {{db.tablespace.address_index}}
25 GRANT SELECT ON word TO "{{config.DATABASE_WEBUSER}}";
27 DROP SEQUENCE IF EXISTS seq_word;
28 CREATE SEQUENCE seq_word start 1;
29 GRANT SELECT ON seq_word to "{{config.DATABASE_WEBUSER}}";