Now takes also stdin, so you can pipe queries