• Some other things to consider:

    1. Do you have indices on the join columns? (MWID, [Org Eenheid Code], BEGINDATUM)

    2. If you have an index on BEGINDATUM, the expression

    DATEPART(ISO_WEEK,A.BEGINDATUM)= DATEPART(ISO_WEEK,B.BEGINDATUM)

    will stop SQL server from using that index (Since it's a function call it's not a SARG). To get around that, try to reformulate it as

    BEGINDATUM > <beginning of the week> AND BEGINDATUM < <beginning of following week>