added support for additional arguments in query