skip to Main Content

How can I display book details in Laravel using Eloquent join and where clauses?

Undefined property: IlluminateDatabaseQueryBuilder::$title public function show(string $id) { $books = DB::table("book_tbls") ->where("author_tbls.id", "=", $id) ->where("author_tbls.id", "=", "book_tbls . author_id") ->where("categories.id", "=", $id) ->where("categories.id", "=", "book_tbls . category_id"); // $books = book_tbl::find($id); return view('books.show', compact('books')); } I am learning laravel for…

VIEW QUESTION
Back To Top
Search