fix sql statement

Signed-off-by: Sebastian Schüpbach <sebastian.schuepbach@unibas.ch>
2 jobs for master in 4 minutes and 34 seconds (queued for 1 second)