I’m putting myself through the beginning paces with Yii. I’ve noticed that Gii’s been having some trouble defining model relations if my tables are prefixed with tbl_. I’ve three tables, tbl_project, tbl_user and a join table, tbl_project_user_assignment.
When I generate the crud for tbl_project it defines the relationship with tbl_user as tblUser, not user. If I drop the tbl_ prefix everything works fine, so it’s not a huge deal, but it does make me wonder if I’m doing something wrong.
Turns out that setting that prefix in my main, will not affect non prefixed tables, and everything works just fine. Im not sure how it works , but it does… Maybe someone could shed some light on this ?