Mercurial > gemma
diff pkg/scheduler/boot.go @ 2054:b03e487117df unify_imports
Scheduler: Fixed booting SQL statements.
author | Sascha L. Teichmann <sascha.teichmann@intevation.de> |
---|---|
date | Mon, 28 Jan 2019 09:55:28 +0100 |
parents | c06a2e5397fc |
children | 6594903a14e8 |
line wrap: on
line diff
--- a/pkg/scheduler/boot.go Sun Jan 27 23:19:30 2019 +0100 +++ b/pkg/scheduler/boot.go Mon Jan 28 09:55:28 2019 +0100 @@ -30,14 +30,20 @@ FROM import.import_configuration c JOIN import.import_configuration_attributes a ON c.id = a.import.import_configuration_id -WHERE - c.id IN (SELECT import_configuration_id WHERE k = 'cron')` +WHERE c.id IN ( + SELECT import_configuration_id + FROM import.import_configuration_attributes + WHERE k = 'cron')` scheduledIDsSQL = ` -SELECT id from import.import_configuration +SELECT id +FROM import.import_configuration WHERE username = $1 - AND id IN (SELECT import_configuration_id WHERE k = 'cron')` + AND id IN ( + SELECT import_configuration_id + FROM import.import_configuration_attributes + WHERE k = 'cron')` ) func init() { go boot() }