- $sSQL = "insert into placex (osm_type,osm_id,class,type,postcode,country_code,geometry) ";
- $sSQL .= "select 'P',nextval('seq_postcodes'),'place','postcode',postcode,country_code,";
- $sSQL .= "ST_SetSRID(ST_Point(x,y),4326) as geometry from (select country_code,postcode,";
+ $sSQL = "insert into placex (osm_type,osm_id,class,type,address,country_code,geometry) ";
+ $sSQL .= "select 'P',nextval('seq_postcodes'),'place','postcode',";
+ $sSQL .= "hstore('postcode', pc),country_code,";
+ $sSQL .= "ST_SetSRID(ST_Point(x,y),4326) as geometry from (select country_code,";
+ $sSQL .= "address->'postcode' as pc,";