Last active
October 13, 2020 10:18
-
-
Save taylordowns2000/5d3f48075784a6c112feb8c8376f0ded to your computer and use it in GitHub Desktop.
This file contains bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
// Note that for Postgres you're mapping data from questions to specific columns | |
upsert('assessment_site', 'ON CONSTRAINT assessment_site_pkey', { | |
study_id: 1000, | |
site_id: 1001, | |
admin_level_3: state.data.body['survey_info/district'], | |
site_name: state.data.body['survey_info/village'], | |
enumerator_name: state.data.body.surveyorName, | |
date_of_submission: state.data.body.dateCaptured, | |
// ... | |
}); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment