From 419f3eb8ca51a64d02d7a31ff6d9a52b01eccc63 Mon Sep 17 00:00:00 2001 From: "Leigh B. Stoller" Date: Wed, 18 Jun 2008 21:56:21 +0000 Subject: [PATCH] Add filter by pre-reserve pid. --- db/avail.in | 17 ++++------------- 1 file changed, 4 insertions(+), 13 deletions(-) diff --git a/db/avail.in b/db/avail.in index e0e639fa0..0d693887e 100644 --- a/db/avail.in +++ b/db/avail.in @@ -105,23 +105,14 @@ if (defined($args{"ver"})) { $cols .= ",d.version"; $cond .= " and d.version='".$args{"ver"}."'" if $args{"ver"} ne '='; } -# if (defined($args{"deltas"})) { -# $os = 1; -# $delta=1; -# $cols .= ",e.delta_id"; -# $cond .= " and e.delta_id='".$args{"deltas"}."'" if $args{"deltas"} ne '='; -# } - if ($os) { $join .= " left join partitions as c on a.node_id=c.node_id"; $join .= " left join os_info as d on c.osid=d.osid"; } - -# if ($delta) { -# $join .= " left join delta_inst as e on c.node_id=e.node_id ". -# "and c.partition=e.partition"; -# } - +if (defined($args{"prereserve"})) { + $pid = $args{"prereserve"}; + $cond .= " and a.reserved_pid='$pid' "; +} my $cmd = "select $cols from $join where $cond order by $order $limit"; -- GitLab