$results = User::with([
'country' => function ($query) {
$query->select('id','name');
},'posts' => function ($query) {
$query->select('id','user_id','title');
},'posts.attachments' => function ($query) {
$query->select('id','post_id','type');
}])->get(['id','country_id','name']);