execquery: hacky version that works

Need to figure out how to do this "right"

Signed-off-by: Daniel Halperin <dhalperi@cs.washington.edu>