falls back to entity_id if no external_id