Hacker News new | ask | show | jobs
by Tehdasi 1096 days ago
Never specifically heard about this terminology until now, but after looking, yeah, I can see why ppl prefer 'artificial' keys to natural ones. From the animal shelter example, for people it uses email as the 'natural' key, which immediately runs up against 1,2,3 and 7 in https://beesbuzz.biz/code/439-Falsehoods-programmers-believe...
1 comments

"Natural Key" actually refers to column(s) already available in the dataset you are turning into a row that is unique by row, and thus a candidate for being the key. (Subject to all the normalization, etc.).

An artificial key is a column of made-up data added to the rest of the column. It has no use other than to provide uniqueness. In most cases there is already a unique candidate key in your data.