Two Newbie Questions to which I could not find existing answers:
1) I see in MSSQL2000, in the sample Pubs database, the roysched table and the discounts table have no primary keys? Isn't this a relational best-practice no-no? In other words, shouldn't you always have a primary key, even if you have to resort to using a unique "identity" column? If so, why then would MS do this as an example?
2) If you have a table that has a naturally occurring unique key candidate column, such as a table of automobile brands, Ford, GM, Toyota, Mercedes, etc., which are unique and you want to enforce this (regardless of whether this column is the primary key or not), then is there any reason why you would add or need an identity column and use that as the primary key instead of the brand column, which you want to make unique anyway?
1) I see in MSSQL2000, in the sample Pubs database, the roysched table and the discounts table have no primary keys? Isn't this a relational best-practice no-no? In other words, shouldn't you always have a primary key, even if you have to resort to using a unique "identity" column? If so, why then would MS do this as an example?
2) If you have a table that has a naturally occurring unique key candidate column, such as a table of automobile brands, Ford, GM, Toyota, Mercedes, etc., which are unique and you want to enforce this (regardless of whether this column is the primary key or not), then is there any reason why you would add or need an identity column and use that as the primary key instead of the brand column, which you want to make unique anyway?