Stephan van Hulst wrote:What rows do you get when you run the following query?
If I just replace the both queries of the union, than I get an error: "
java.lang.ClassCastException: class java.util.UUID cannot be cast to class java.lang.String (java.util.UUID and java.lang.String are in module java.base of loader 'bootstrap')"
I've convert that query in SQL than it returns the UUID of the organisation (REG_ORG) what I expect and it is one value. The MEDEWERKER is not linked to more than one organisation, that's maybe what you thought?
I think my Jooq query is not correct, but...? And the union may return more value's, because a dropdown is filled the names of the REG_ORG.