You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
I have an M:N relation table named users_widgets. It gets named UsersWidget by the logic to make it singular; that's not great.
I couldn't find any documentation that table renaming is possible.
Then I stumbled on #435 and more importantly e30cde1
Based on that, it seems
There's no way to rename a struct field X differently than a table name X
And looking at that, I realized struct fields also cannot be renamed differently for two different struct types.
Table names go through the renaming after Singular. That means I need rename: users_widget: blah. That's confusing; the key is neither present in my database nor in the default generated code.
And, where we started from, none of this is documented.
The text was updated successfully, but these errors were encountered:
I have an M:N relation table named
users_widgets
. It gets namedUsersWidget
by the logic to make it singular; that's not great.I couldn't find any documentation that table renaming is possible.
Then I stumbled on #435 and more importantly e30cde1
Based on that, it seems
There's no way to rename a struct field X differently than a table name X
And looking at that, I realized struct fields also cannot be renamed differently for two different struct types.
Table names go through the renaming after
Singular
. That means I needrename: users_widget: blah
. That's confusing; the key is neither present in my database nor in the default generated code.And, where we started from, none of this is documented.
The text was updated successfully, but these errors were encountered: