Should a database table have default values?
问题 I was having a discussion with a developer at work on the issue of should a table use default values. Is there a hard and fast rule on this or is it a gray area in best practices? 回答1: My rule: if many records will use that default (at least initially) then I like to use it as a default. For example, an image table for products in an online store might have a default path of images/NoPictureYet.png . Eventually, those will get replaced, but for batch loads of data where the pictures simply