命名数据库表和视图 [英] Naming Database Tables and Views

查看:91
本文介绍了命名数据库表和视图的处理方法,对大家解决问题具有一定的参考价值,需要的朋友们下面随着小编来一起学习吧!

问题描述

我最近问了一个同事,为什么他们在所有数据库表名的末尾都包含_TABLE.他们说这是他们工作过的另一家组织的标准.其他同事在视图开始时使用V_.
这是好习惯吗?

I recently asked a colleague why they had included _TABLE at the end of all their database table names. They said it had been a standard at another orgainisation they had worked for. Other colleagues use V_ at the start of views.
Is this good practice?

推荐答案

一致性是最好的方法.在我的书中,在对象名称的末尾添加_TABLE或_VIEW是过分的,但是如果数据库是按这种方式设计的,则不会违反常规.

Consistency is the best approach. Adding a _TABLE or _VIEW at the end of an object name is overkill in my book, but if the database is designed that way, I wouldn't break from convention.

让您的同事将他以前的组织的命名约定引入一个新的组织而又不检查本地"标准是不明智的做法.

For your colleague to bring his naming convention from a previous organization into a new one without checking 'local' standards is bad practice.

这篇关于命名数据库表和视图的文章就介绍到这了,希望我们推荐的答案对大家有所帮助,也希望大家多多支持IT屋!

查看全文
登录 关闭
扫码关注1秒登录
发送“验证码”获取 | 15天全站免登陆