Support the ongoing development of Laravel.io →

4,606 Threads

Filter not exist columns in Eloquent model

How can I modify the ~~~static::creating~~~ function to avoid "Column not found: 1054 Unknown c...

0 Likes
0 Replies

Eloquent set random not duplicate id when creating records

This is the code of my Eloquent model: protected static function boot() { parent::boot(); s...

0 Likes
2 Replies

Group result/collection by field

I'm pulling an actor from the database. In the actor's view I want to see a list of all movies my ac...

0 Likes
0 Replies
posted 10 years ago

Connecting MySQL over SSL

How i connect MySQL using SSL. How I can configure it in databse.php ? I added all my .pem files alo...

0 Likes
1 Replies
Solved
posted 10 years ago

What is the MySQL datatype SET equivalent in Laravel Schema?

Laravel Schema has a command for ENUM equivalent to the table. What is the SET equivalent to the tab...

0 Likes
1 Replies

eloquent relationship validation

I have a Model "Houses" that has a location_id field so every record has a relationship wi...

0 Likes
1 Replies

What's the best / correct way to extend a model and structure the DB tables

Model Woman extends Homospaien Model Man extends Homosapien Table "homosapien" contains al...

0 Likes
1 Replies
posted 10 years ago

Help me with relations please ^^

Hey guys my DB is like you see above. Now i am wondering how i can print out the names of the weapo...

0 Likes
8 Replies
Solved

SQLSTATE Syntax error when using Eloquent join

I'm very new to Laravel and MVC's in general (third day of using Laravel), so please bear with me. I...

0 Likes
2 Replies
Solved

Homestead - Connecting to Postgres

I can connect to the Homestead MySQL database no problem with: vagrant@homestead:~$ mysql -uhomestea...

0 Likes
2 Replies
Solved

Creating and using models

For months, I've been placing all my logic in my controllers. Today, I would like to steer clear of...

0 Likes
1 Replies

checkboxes in form::model

I set up a migration to include a boolean value in my model (using the boolean() method). That trans...

0 Likes
0 Replies

Relationship Query

Is there any place that shows real world examples of Relationship querys and fetching associated dat...

0 Likes
5 Replies
posted 10 years ago

Multiple aggregates in one query

How would I do "SELECT Count(*), Min(some_field), Max(some_field) FROM some_table" in the...

0 Likes
2 Replies
Solved

Returning records using withTrashed()

An Owner has many Cars... And in my blade page I have this... {{{$car->Owner->name}}} And tha...

0 Likes
3 Replies

Trait 'Illuminate\Auth\UserTrait' not found

HI i searched Google but did not find anything about this and i never had this error before in Larav...

0 Likes
0 Replies

Whats the opposite of ->associate() ?

I'm trying to figure out the easiest and most effective way up updating hasMany() and belongsTo() re...

0 Likes
2 Replies

One of my "belongsTo" doesn't work - why?

Hi! Just started using Laravel (4.1.30) for a project at work. So far it's just amazing, totally hoo...

0 Likes
2 Replies
Solved

How do I use foreign keys in my blade template file?

When I use {{ $hotel->userid->username }} in my blade templates, I get this exception. "T...

0 Likes
1 Replies

Migration help

I am converting a site with 50+ tables, some have 35+ columns and setting up the controller / views...

0 Likes
2 Replies

Thanks to our community

Solutions given in the past year. Excluding solutions from thread authors.

Moderators

We'd like to thank these amazing companies for supporting us

Your logo here?

Laravel.io

The Laravel portal for problem solving, knowledge sharing and community building.

© 2025 Laravel.io - All rights reserved.