PHP aggregates function

An aggregate function operates on a series of values and returns a single summary value, because an aggregate function typically operates on the values in columns and aggregate functions are…

0 Comments

Row count and sum in laravel

$count = DB::table('is_profile_completed')->where('userd', $userid)->count(); $sum = DB::table('is_profile_completed')->where('userd', $userid)->sum('salary'); $data = DB::table('posts')->where('post_status_for_frontend', 1)->orderBy('updated_at', 'desc')->paginate(4); {{count($data)}}  

0 Comments