Ank13/ops_hospital_mapper — pull request #83 by codesliced (2013-07-10 21:15:14+00:00)
Title: Usa woot

Directions for adding USA to your local DB:

- pull from master
- in hospital model, comment out the line : self.primary_key = "provider_id"
- in procedure model, comment out the line : self.primary_key = "provider_id"
rake db:drop
rake db:create
rake db:migrate
rake db:import_csv_complications
rake db:import_csv_hospitals
rake db:import_usa_procedures
rake db:import_csv_hospitals_procedures
rake db:import_csv_outcomes
rake db:import_csv_patient_surveys
rake db:import_csv_stateprocedure
rake db:import_csv_procedure_description
rake db:calc_cost_index

After raking, go to rails console to make sure you have 3337 hospitals, over 163K hospitals_procedures, etc.

THEN
- in hospital model, uncomment the line : self.primary_key = "provider_id"
- in procedure model, uncomment the line : self.primary_key = "provider_id"

You are good to go after that.