Why VARCHARs (Strings) make bad Keys.

keys

When you construct a database, you often have to make decisions based on incomplete information. Oftentimes you’re given a small subset of data and you have to decide what kind of datatype goes where, how entities naturally link to each other and when to denormalize.

There’s one debate when it comes to building out tables for databases and that’s what do you use as the key.