In this tutorial, we will discover how to use wheretime eloquent query in laravel application.

Given below are examples of wheretime eloquent query.



Example 1:

/**
* The attributes that are mass assignable.
*
* @var array
*/
public function index()
{
    $users = User::whereTime('created_at', '=', '03:03:03')
                ->get();
    dd($users);
    
}



Example 2:

* The attributes that are mass assignable.
*
* @var array
*/
public function index()
{
    $users = DB::table('users')
                ->whereTime('created_at', '=', '03:03:03')
                ->get();
    dd($users);
    
}


I hope this example helps you.