codeforkansascity / address-api

A address database accessible through an API that will return attributes about the address, neighborhood, council district, zoning...
http://address-api.codeforkc.org
MIT License
5 stars 9 forks source link

Reload KCMO Neighborhoods from new file containing North of the River #49

Closed zmon closed 8 years ago

zmon commented 8 years ago

This is based off of Load KC Neighborhood shape file #33 which was the first load that did not include North of the river.

shp2pgsql -g geom -I  NeighborhoodCensus.shp address_spatial.kcmo_address_nbhd_tmp | psql -d code4kc

results in

\d address_spatial.kcmo_address_nbhd_tmp
                                       Table "address_spatial.kcmo_address_nbhd_tmp"
   Column   |          Type          |                                      Modifiers                                      
------------+------------------------+-------------------------------------------------------------------------------------
 gid        | integer                | not null default nextval('address_spatial.kcmo_address_nbhd_tmp_gid_seq'::regclass)
 objectid   | numeric(10,0)          | 
 nbhid      | numeric                | 
 nbhname    | character varying(50)  | 
 shape_area | numeric                | 
 shape_len  | numeric                | 
 geom       | geometry(MultiPolygon) | 
Indexes:
    "kcmo_address_nbhd_tmp_pkey" PRIMARY KEY, btree (gid)
    "kcmo_address_nbhd_tmp_geom_gist" gist (geom)
DELETE FROM address_spatial.mo_kc_city_neighborhoods;
php load.php

Results in

Totals
--------------------------------------------------------------------------
table                              insert     update        N/A      ERROR
input                                   0          0          0          0
city_address_attributes                 0      97770     101718          0
--------------------------------------------------------------------------

Number of lines processed 199488

This process used 15741 ms for its computations
It spent 3166 ms in system calls
Run time:  2m 33s