mardi 14 décembre 2021

How to write correct way of sql query in php laravel

I want to fetch all data from this table for that i am using query :

      $emp = Employee::where('user_id', '=', $user->id)->first();

    $holidays = Holiday::orderBy('holidays.id', 'desc')->take(5)->where('holidays.id', '=', $emp->id)->get();

It is not giving me any result. I am new to php can anyone help me out yrr?

Holiday Table



from Newest questions tagged laravel-5 - Stack Overflow https://ift.tt/3EWyOub
via IFTTT

Aucun commentaire:

Enregistrer un commentaire