Change: used the param -q instead of -g for logical use of indicating query