laravel check if value is in table code example
Example 1: laravel check record exists
$user = User::where('email', '=', Input::get('email'))->first();
if ($user === null) {
// user doesn't exist
}
Example 2: check if column has value in laravel eloquent
->where(function ($query) {
$query->whereNull('exam_ends_at')
->orWhere('exam_ends_at', '>', Carbon::now());
})