]> git.openstreetmap.org Git - nominatim.git/blob - lib-sql/tokenizer/icu_tokenizer_tables.sql
13e1bdb0c5ef520758da15589a01d6cbb0d40555
[nominatim.git] / lib-sql / tokenizer / icu_tokenizer_tables.sql
1 DROP TABLE IF EXISTS word;
2 CREATE TABLE word_icu (
3   word_id INTEGER,
4   word_token text NOT NULL,
5   type text NOT NULL,
6   info jsonb
7 ) {{db.tablespace.search_data}};
8
9 CREATE INDEX idx_word_word_token ON word
10     USING BTREE (word_token) {{db.tablespace.search_index}};
11 GRANT SELECT ON word TO "{{config.DATABASE_WEBUSER}}";
12
13 DROP SEQUENCE IF EXISTS seq_word;
14 CREATE SEQUENCE seq_word start 1;
15 GRANT SELECT ON seq_word to "{{config.DATABASE_WEBUSER}}";