query-add and query-set arguments validation

Validate the number of arguments when `perform` is called