diff --git a/data/db/covid19data.sql b/data/db/covid19data.sql index 73c88f3204a84b6620c8b1b848e20bf0ecab14f2..3c78fc715f2c909bf296413a611c60dbda92797d 100644 --- a/data/db/covid19data.sql +++ b/data/db/covid19data.sql @@ -1,3 +1,3 @@ version https://git-lfs.github.com/spec/v1 -oid sha256:c7321e1dcf41cebfc7c05fee789e05d9e4cb32279311a83df81b7d0be005cfbe -size 105853994 +oid sha256:31395443242b9a71a82b7cd3b6445fb16b6123a5d49df5f6633b80be00392c12 +size 104401898 diff --git a/data/db/covid19data.sql.gz b/data/db/covid19data.sql.gz deleted file mode 100644 index ca32ebb0552a23564bd824a7433236b473e96132..0000000000000000000000000000000000000000 --- a/data/db/covid19data.sql.gz +++ /dev/null @@ -1,3 +0,0 @@ -version https://git-lfs.github.com/spec/v1 -oid sha256:5703330ed140c243cbb6db81ead92ea618f13029b0c8f84815bd96cf382133c5 -size 18436889 diff --git a/src/covid19/blueprints/admin/admin_service.py b/src/covid19/blueprints/admin/admin_service.py index 1fe943d4fa17e0332795d62a71933f0c96c62708..f35a29ce222e386cef671222f261bfe9412aa7cb 100644 --- a/src/covid19/blueprints/admin/admin_service.py +++ b/src/covid19/blueprints/admin/admin_service.py @@ -27,7 +27,7 @@ class AdminService: db = app.config['SQLALCHEMY_POSTGRES_DB'] cmd = 'pg_dump -U '+user+' -h '+url+' '+db\ +' --clean --if-exists --no-tablespaces '\ - +' --on-conflict-do-nothing --rows-per-insert=200 --column-inserts '\ + +' --on-conflict-do-nothing --rows-per-insert=1000 --column-inserts '\ +' --quote-all-identifiers --no-privileges > '\ + self.file_path app.logger.info(" start: "+str(cmd)) @@ -59,7 +59,7 @@ class AdminService: url = app.config['SQLALCHEMY_POSTGRES_URL'] db = app.config['SQLALCHEMY_POSTGRES_DB'] cmd_list = [ - 'pgsql -U ' + user + ' -h ' + url + ' ' + db + ' < ' + self.file_path + 'psql -U ' + user + ' -h ' + url + ' ' + db + ' < ' + self.file_path ] for cmd in cmd_list: returncode = self.__run_ome_shell_command(cmd)