{"action":"created","issue":{"url":"https://api.github.com/repos/yiisoft/yii2/issues/9815","labels_url":"https://api.github.com/repos/yiisoft/yii2/issues/9815/labels{/name}","comments_url":"https://api.github.com/repos/yiisoft/yii2/issues/9815/comments","events_url":"https://api.github.com/repos/yiisoft/yii2/issues/9815/events","html_url":"https://github.com/yiisoft/yii2/issues/9815","id":109461208,"number":9815,"title":"DB Column and Table Naming","user":{"login":"thejahweh","id":10514993,"avatar_url":"https://avatars.githubusercontent.com/u/10514993?v=3","gravatar_id":"","url":"https://api.github.com/users/thejahweh","html_url":"https://github.com/thejahweh","followers_url":"https://api.github.com/users/thejahweh/followers","following_url":"https://api.github.com/users/thejahweh/following{/other_user}","gists_url":"https://api.github.com/users/thejahweh/gists{/gist_id}","starred_url":"https://api.github.com/users/thejahweh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thejahweh/subscriptions","organizations_url":"https://api.github.com/users/thejahweh/orgs","repos_url":"https://api.github.com/users/thejahweh/repos","events_url":"https://api.github.com/users/thejahweh/events{/privacy}","received_events_url":"https://api.github.com/users/thejahweh/received_events","type":"User","site_admin":false},"labels":[],"state":"closed","locked":false,"assignee":null,"milestone":null,"comments":3,"created_at":"2015-10-02T09:40:20Z","updated_at":"2015-10-02T11:19:21Z","closed_at":"2015-10-02T10:48:45Z","body":"Would it not make sense, to use a more strict naming convention, in places where the DB is used?\r\n\r\nI know that this was discussed more than once, but it felt wrong as I compared some properties of normal classes with properties of ActiveRecords.\r\n\r\nIn Yii2 a **table** is used in a class, which is named in the **UpperCamelCase** format.\r\nThe **columns** are the properties in the object which should be named in the **lowerCamelCaseFormat**.\r\n\r\nBut if I look in the migration or the rbac module everything is snake_case. This leads to objects with snake_case properties which is not recomended in the [code style sheet] (https://github.com/yiisoft/yii2/blob/master/docs/internals/core-code-style.md) of Yii2.\r\n\r\nI know too, that this is a very personal or company oriented decision, but if felt that it should be like my example below. In my opinion this should be in this way because of the object oriented way Yii2 handles SQL tables, rows and columns.\r\n```\r\nClassName->propertyName\r\nTableName.columnName\r\n```"},"comment":{"url":"https://api.github.com/repos/yiisoft/yii2/issues/comments/144993453","html_url":"https://github.com/yiisoft/yii2/issues/9815#issuecomment-144993453","issue_url":"https://api.github.com/repos/yiisoft/yii2/issues/9815","id":144993453,"user":{"login":"thejahweh","id":10514993,"avatar_url":"https://avatars.githubusercontent.com/u/10514993?v=3","gravatar_id":"","url":"https://api.github.com/users/thejahweh","html_url":"https://github.com/thejahweh","followers_url":"https://api.github.com/users/thejahweh/followers","following_url":"https://api.github.com/users/thejahweh/following{/other_user}","gists_url":"https://api.github.com/users/thejahweh/gists{/gist_id}","starred_url":"https://api.github.com/users/thejahweh/starred{/owner}{/repo}","subscriptions_url":"https://api.github.com/users/thejahweh/subscriptions","organizations_url":"https://api.github.com/users/thejahweh/orgs","repos_url":"https://api.github.com/users/thejahweh/repos","events_url":"https://api.github.com/users/thejahweh/events{/privacy}","received_events_url":"https://api.github.com/users/thejahweh/received_events","type":"User","site_admin":false},"created_at":"2015-10-02T11:19:21Z","updated_at":"2015-10-02T11:19:21Z","body":"@samdark this is not what I wanted to archive. The case is that the actual column names do not match the expected naming convention. Column names should be the same as in the objects, nobody wants a conversion this would be leading to confusion."}}