Restore grants for dynamic tables in tokenizer, migration, and tiger import

This commit is contained in:
Itz-Agasta
2026-01-30 20:43:57 +05:30
parent 5e2ce10fe0
commit e021f558bf
4 changed files with 11 additions and 5 deletions

View File

@@ -42,9 +42,4 @@ GRANT SELECT ON country_osm_grid TO "{{config.DATABASE_WEBUSER}}";
-- Tokenizer tables (word table)
{% if 'word' in db.tables %}
GRANT SELECT ON word TO "{{config.DATABASE_WEBUSER}}";
{% endif %}
-- Tiger import table (if exists)
{% if 'location_property_tiger_import' in db.tables %}
GRANT SELECT ON location_property_tiger_import TO "{{config.DATABASE_WEBUSER}}";
{% endif %}

View File

@@ -13,6 +13,8 @@ CREATE INDEX IF NOT EXISTS idx_location_property_tiger_parent_place_id_imp
CREATE UNIQUE INDEX IF NOT EXISTS idx_location_property_tiger_place_id_imp
ON location_property_tiger_import (place_id) {{db.tablespace.aux_index}};
GRANT SELECT ON location_property_tiger_import TO "{{config.DATABASE_WEBUSER}}";
DROP TABLE IF EXISTS location_property_tiger;
ALTER TABLE location_property_tiger_import RENAME TO location_property_tiger;