I probably should never have taken this class of psychology, but due to the fact that there is the word "id", I always use the abbreviation for the identifier, so I use "ID". I experimented using both ID and ProductID for the primary key name. Since I use LINQ and just map the class in the designer, I decided to name the columns the way I want them in my code. Since I prefer to have product.ID than product.ProductID , I use a shorter name. For foreign keys, I use the table / column format (without a separator), so the foreign key will become ProductID. This is not a problem for me in my code, because I almost always use the displayed object, for example, cart.Product , and not the key itself, cart.ProductID .
EDIT : Note. I assume that the purpose of the .NET platform is using (mainly) naming conventions from .NET. If I were doing Rails development, they would probably be lowercase, and I would use underscores as separators.
source share