mardi 6 avril 2021

Laravel Get Join Data And Non Join Data

I am trying to get two tables data using join

    // $participantstation = DB::table('participant_station')
        // ->join('reviews', 'participant_station.id', '=', 'reviews.participant_station_id')
        // ->select('reviews.*', 'participant_station.*')
        // ->where('station_id',$stn->id)
        // ->where('status', '100')
        // ;

Still some partipant are not linked , that means - participant_station.id', '=', 'reviews.participant_station_id

if I try this code it only shows the linked participants

is there any way to show both linked and non-linked participants using such query?

Thank you



via Chebli Mohamed

Aucun commentaire:

Enregistrer un commentaire