laravel get joins code example
Example 1: join in laravel eloquent
$customer = DB::table('customers')
->join('shops', 'customers.shop_id', '=', 'shops.shop_id')
->where('customer_contact', $contact_no)
->get();
Example 2: laravel query builder select first
$user = DB::table('users')->where('name', 'John')->first();
var_dump($user->name);