Skip to content

Commit 8232203

Browse files
fixes #56 - footnote to explain why use plural
1 parent 64b60b2 commit 8232203

File tree

1 file changed

+11
-3
lines changed

1 file changed

+11
-3
lines changed

docs/2-naming-conventions/naming-conventions.md

Lines changed: 11 additions & 3 deletions
Original file line numberDiff line numberDiff line change
@@ -56,7 +56,7 @@ Examples:
5656

5757
### Column
5858

59-
Singular name of what is stored in the column (unless the column data type is a collection, in this case you use plural names)
59+
Singular name of what is stored in the column (unless the column data type is a collection, in this case you use plural[^1] names)
6060

6161
Add a comment to the database dictionary for every column.
6262

@@ -182,7 +182,7 @@ Examples:
182182

183183
### Table
184184

185-
Plural name of what is contained in the table (unless the table is designed to always hold one row only – then you should use a singular name)
185+
Plural[^1] name of what is contained in the table (unless the table is designed to always hold one row only – then you should use a singular name)
186186

187187
Add a comment to the database dictionary for every table and every column in the table.
188188

@@ -223,7 +223,7 @@ Examples:
223223

224224
### View
225225

226-
Plural name of what is contained in the view.
226+
Plural[^1] name of what is contained in the view.
227227
Optionally suffixed by an indicator identifying the object as a view (mostly used, when a 1:1 view layer lies above the table layer)
228228

229229
Add a comment to the database dictionary for every view and every column.
@@ -234,3 +234,11 @@ Examples:
234234

235235
* `active_orders`
236236
* `orders_v` - a view to the orders table
237+
238+
[^1]:
239+
We see a table and a views as a collection. A jar containing beans is labeled with "beans".
240+
In Java we call such collection also beans (`List<Bean> beans`) and name an entry bean
241+
(`for (Bean bean : beans) {...}`). An entry of a table is a row (singular) and a table can
242+
contain an unbounded number of rows (plural). This and the fact that the Oracle database uses
243+
the same concept for their tables and views lead to the decision to use the plural
244+
to name a table or view.

0 commit comments

Comments
 (0)