smallAreaHealthStatisticsUnit / rapidInquiryFacility

The Rapid Inquiry Facility (RIF) helps epidemiologists and public health researchers in environmental health activities.
GNU Lesser General Public License v3.0
14 stars 5 forks source link

Installer: consider running the SQL scripts directly #145

Open devilgate opened 5 years ago

devilgate commented 5 years ago

Can we run the SQL scripts directly from Python?

That is, not by calling the psql or sqlcmd commands, but by passing the script file or its contents to a library function that connects to Postgres or SQL server? Maybe Psycopg (for Postgres), since we're already importing that. The advantage would be that the user wouldn't need to have the relevant bin directories in their PATH. The disadvantage might be that it's just to much hassle to make it work.