added possibility to create a query builder in the definition