X-Git-Url: https://git.openstreetmap.org./nominatim.git/blobdiff_plain/4fcb66df929dc1cb34d0e58ec5ab4b5ffc04fc4e..dea1d67d03fb3a28eb70c2e1740c1e1470b30261:/sql/tables.sql

diff --git a/sql/tables.sql b/sql/tables.sql
index 949dc6ff..0559abd4 100644
--- a/sql/tables.sql
+++ b/sql/tables.sql
@@ -36,6 +36,7 @@ GRANT SELECT ON new_query_log TO "{www-user}" ;
 
 GRANT SELECT ON TABLE country_name TO "{www-user}";
 GRANT SELECT ON TABLE gb_postcode TO "{www-user}";
+GRANT SELECT ON TABLE us_postcode TO "{www-user}";
 
 drop table IF EXISTS word;
 CREATE TABLE word (
@@ -69,6 +70,15 @@ CREATE TABLE location_area (
 
 CREATE TABLE location_area_large () INHERITS (location_area);
 
+DROP TABLE IF EXISTS location_area_country;
+CREATE TABLE location_area_country (
+  place_id BIGINT,
+  country_code varchar(2),
+  geometry GEOMETRY(Geometry, 4326)
+  ) {ts:address-data};
+CREATE INDEX idx_location_area_country_geometry ON location_area_country USING GIST (geometry) {ts:address-index};
+
+
 drop table IF EXISTS location_property CASCADE;
 CREATE TABLE location_property (
   place_id BIGINT,
