count column eloquent laravel

PHP
$total = Post::sum('views');


Source

Also in PHP: