Change out pg_query with pg_query_params

Also, took care of a typo. Because I'm meta like that.