Information générale
Catégorie:
The Mere Mortals Framework
Titre:
Table Design and iid Primary Key Naming Convention Options
In the new application MMs Quick Start produces, it appears that Oakleaf recommends using iid as the field name for the primary keys in tables. There are however, at least three options I know of;
1. Use iid, as is the case in many of the MM's new application tables.
2. Use i[table abbreviation]id.
3. Use iid[table abbreviation].
There are advantages and disadvantages to each option.
Options two and three have the advantage that a developer can look at the table will see a 'standard' id field name to use in tables that relate to it.
Example: Company.DBF would have iidCo field, so when looking for a field to use to relate to this table, one looks at the Company.DBF and instantly sees that the iidCo 'standard' field name is the one to use.
What are the advantages to using 1. iid as the naming convention option?
Which option would you recommend using?
Suivant
Répondre
Voir le fil de ce thread
Voir le fil de ce thread à partir de ce message seulement
Voir tous les messages de ce thread
Voir tous les messages de ce thread à partir de ce message seulement