Use outerjoin to connect with hosts table as it may be empty for some jobs