DO moved to main query and made executable.
Removed unused local method.
Added executable main query joins.