Branch: refs/heads/master
Home: https://github.com/NixOS/hydra
Commit: 966cc2213117c15a6b09d2c4e179b0929cff3023
https://github.com/NixOS/hydra/commit/966cc2213117c15a6b09d2c4e179b0929cff3023
Author: Rob Vermaas <[email protected]>
Date: 2012-04-21 (Sat, 21 Apr 2012)
Changed paths:
M src/script/hydra-update-gc-roots
Log Message:
-----------
Fix query for certain postgresql versions.
diff --git a/src/script/hydra-update-gc-roots b/src/script/hydra-update-gc-roots
index a8c9de8..e22b576 100755
--- a/src/script/hydra-update-gc-roots
+++ b/src/script/hydra-update-gc-roots
@@ -94,7 +94,7 @@ foreach my $project ($db->resultset('Projects')->search({}, {
order_by => ["name
[ "select b2.id from Builds b2 join " .
" (select distinct job, system, coalesce( " .
" (select id from builds where project = b.project and
jobset = b.jobset and job = b.job and system = b.system and finished = 1 and
buildStatus = 0 order by id desc offset ? limit 1)" .
- " , 0) nth from builds b where project = ? and jobset = ?
and isCurrent = 1) x " .
+ " , 0) as nth from builds b where project = ? and jobset
= ? and isCurrent = 1) x " .
" on b2.project = ? and b2.jobset = ? and b2.job = x.job and
b2.system = x.system and (id >= x.nth) where finished = 1 and buildStatus = 0"
, [ '', $keepnr - 1 ], [ '', $project->name ], [ '',
$jobset->name ], [ '', $project->name ], [ '', $jobset->name ] ] }
},
================================================================
_______________________________________________
nix-commits mailing list
[email protected]
http://lists.science.uu.nl/mailman/listinfo/nix-commits