Specify another name as the second parameter on the call to belongsToMany().
Edit: And, of course, use that name in your migration file as well.
Be part of JetBrains PHPverse 2026 on June 9 – a free online event bringing PHP devs worldwide together.
hi.I want to save my quiz scores in database using scores table which has user_id,post_id,correct_num.with laravel name rules its name must be post_user but I've already used this name for comments table.
is there anyway that I create this table with my custom name?
Specify another name as the second parameter on the call to belongsToMany().
Edit: And, of course, use that name in your migration file as well.
Please or to participate in this conversation.