Support the ongoing development of Laravel.io →
Configuration Database Eloquent
Last updated 2 months ago.
0

You can override all the naming if you have to.

In your example your model would be TbHappyCustomer if following convention.

Last updated 6 years ago.
0

thanks lagbox. What about if I need a pivot table for 2 tables that have "_" ?

0

Then it will be those two model names snake cased in alpha order. some_other_model_tb_happy_customer. This can be overriden when declaring the belongsToMany relationship if needed.

0

Sign in to participate in this thread!

Cloudways

Your banner here too?

Moderators

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

Your logo here?

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

© 2022 Laravel.io - All rights reserved.