def set_command_type(self, _command_type):
        if _command_type in QUERY_TYPES:
            # user choice if present
            self._command_type = _command_type

        else:
            raise PyOrientBadMethodCallException(
                _command_type + ' is not a valid command type', []
            )

        return self