Skip to content
GitLab
Menu
Projects
Groups
Snippets
Help
Help
Support
Community forum
Keyboard shortcuts
?
Submit feedback
Contribute to GitLab
Sign in / Register
Toggle navigation
Menu
Open sidebar
emulab
emulab-devel
Commits
1ba82c91
Commit
1ba82c91
authored
Jan 30, 2003
by
Leigh B. Stoller
Browse files
Speed up query that was taking 1 second, now down to 0.01.
parent
ff99b93b
Changes
1
Hide whitespace changes
Inline
Side-by-side
capture/capserver.c
View file @
1ba82c91
/*
* EMULAB-COPYRIGHT
* Copyright (c) 2000-200
2
University of Utah and the Flux Group.
* Copyright (c) 2000-200
3
University of Utah and the Flux Group.
* All rights reserved.
*/
...
...
@@ -205,11 +205,11 @@ main(int argc, char **argv)
* Figure out current owner. Might not be a reserved node,
* in which case set it to root/wheel by default.
*/
res
=
mydb_query
(
"select g.unix_gid from
groups
as
g
"
"left join experiments as e "
"
on g
.pid=e.pid and
g.g
id=e.
g
id "
"left join
reserved as r
"
"
on e
.pid=
r
.pid and
e.eid=r.e
id "
res
=
mydb_query
(
"select g.unix_gid from
reserved
as
r
"
"left join experiments as e
on
"
"
r
.pid=e.pid and
r.e
id=e.
e
id "
"left join
groups as g on
"
"
g
.pid=
e
.pid and
g.gid=e.g
id "
"where r.node_id='%s'"
,
1
,
node_id
);
...
...
Write
Preview
Supports
Markdown
0%
Try again
or
attach a new file
.
Attach a file
Cancel
You are about to add
0
people
to the discussion. Proceed with caution.
Finish editing this message first!
Cancel
Please
register
or
sign in
to comment