Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

address speed when loading files into dose table in DB #136

Open
kdionisio opened this issue Jun 20, 2017 · 0 comments
Open

address speed when loading files into dose table in DB #136

kdionisio opened this issue Jun 20, 2017 · 0 comments
Assignees
Labels

Comments

@kdionisio
Copy link
Contributor

kdionisio commented Jun 20, 2017

It is taking 8+ hrs to load a file into the dose table in the DB, depending on how large the file is. Is there any way we can speed this up? The query being used to load the file into the DB is:

LOAD DATA LOCAL INFILE '/home/kdionisio/S2D_daily_all.csv' INTO TABLE hem_app_dose FIELDS TERMINATED BY ',' ENCLOSED BY '"' ignore 1 lines (person_id, @chemical, day, dir_derm_exp, dir_derm_max, dir_derm_abs, dir_inhal_exp, dir_inhal_mass, dir_inhal_max, dir_inhal_abs, dir_ingest_exp, dir_ingest_abs, hem_app_dose.release, ind_derm_exp, ind_derm_max, ind_derm_abs, ind_inhal_exp, ind_inhal_max, ind_inhal_mass, ind_inhal_abs, ind_ingest_exp, ind_ingest_abs, out_sur, out_air, drain, waste) SET created_at = NOW(), updated_at = NOW(), chemical_id = (SELECT id FROM hem_app_chemical WHERE dtxsid = @chemical), runparams_id=6; 
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

2 participants