Skip to content

Tag: laravel

Multiple form submit in Laravel

Good day everyone, I have a form with multiple inputs in it and I want to pass it onto the database on submit. Here’s what my blade.php looks like: on code: Here’s my attempt to find a solution: on my controller: I’m having the following errors: ErrorException Array to string conversion and …

Laravel Dynamic DB Relation

I didn’t find any solution so i am asking it here.. The id of Team is related with teams in Match ,for this the solution is easy.. but The Problem is that one Match can have 3/4+ no of teams So i have to make it dynamic … Answer As Per @maki10 The working Solution Is

Laravel sql table error when i try to upload

This is the error i get SQLSTATE[HY000]: General error: 1 table posts has no column named caption (SQL: insert into “posts” (“caption”, “image”, “user_id”, “updated_at”, “created_at”) values (Caption, Why is that post table code blade.php…

Convert this SQL into eloquent ORM

I want to convert the following sql statement into eloquent: I did this as like below: The problem is that it is converting to the same sql but showing error. The error is shown below: * order_number, order_id, sum(quantity) as qty, sum(price) as pr from orders right join order_details on orders.id = order_de…

Laravel 6 many to many relationship

In laravel 6, I have 2 models I have third model to join tables Now how can I get all the teachers those are not subscribed by a particular student? For example: Teacher1, Teacher2, Teacher3, Teacher4 are in the Teacher table and Student1, Student2, Student3, Student4 are in the Student table Student1 subscri…