Commit 4d9e2ad6 authored by Leigh B. Stoller's avatar Leigh B. Stoller

Fix up slow query.

parent 08b2b626
......@@ -36,9 +36,8 @@ query_db(struct in_addr ipaddr, struct in_addr *sip,
MYSQL_RES *res;
MYSQL_ROW row;
char dbquery[] =
"select pxe_boot_path, next_pxe_boot_path from nodes as n "
"left join interfaces as i on "
"i.node_id=n.node_id "
"select pxe_boot_path,next_pxe_boot_path from interfaces as i "
"left join nodes as n on i.node_id=n.node_id "
"where i.IP = '%s'";
#define PXEBOOT_PATH 0
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment