Pick out only parts of query I need