Yes, you're saving some space with natural keys, but surrogate keys, like just number (integer) are faster during comparisons. Like you need to compare 4 bytes of integer versus 10-11 for string "CelebCurry\0". Databases grows big, so it's more and more important to use numbers, because actualy indexes are usually smaller with integers than strings. :) Anyway - good videos.
TBH i think it comes down to the size. I bet Facebook would be best with user names. But a smaller database, say a few million, would be better with id's
Would you say that you should use Natural Keys for User interfaces and 3rd party services. Use Surrogate for internal db keys. I am looking at creating a trigger that creates a surrogate key when the columns for a natural key change...because I am also creating a type 2 scd table.
Hi Caleb, thanks for your videos. V helpful. I'm a bit confused around the difference between Natural and Surrogate key. A natural key is basically a collection of columns that if concatenated would yield unique rows in table, which is effectively the same as adding a unique ID as a proxy for those columns. Wouldn't you always need to know what the natural key would be to establish a surrogate key? Thanks
Hey Caleb, awesome video series, really helped me understand the basics of Database management systems. However... Seriously do you only have t-shirts with stars and stribes?! :D
Caleb - Your theatrics were adorable and make these videos entertaining!
Your explanation is the best!
Yes, you're saving some space with natural keys, but surrogate keys, like just number (integer) are faster during comparisons. Like you need to compare 4 bytes of integer versus 10-11 for string "CelebCurry\0". Databases grows big, so it's more and more important to use numbers, because actualy indexes are usually smaller with integers than strings. :)
Anyway - good videos.
TBH i think it comes down to the size. I bet Facebook would be best with user names. But a smaller database, say a few million, would be better with id's
Should you use Surrogate Keys or Natural Keys? Watch this video to find out!
buff.ly/V1CEvh
Would you say that you should use Natural Keys for User interfaces and 3rd party services. Use Surrogate for internal db keys. I am looking at creating a trigger that creates a surrogate key when the columns for a natural key change...because I am also creating a type 2 scd table.
Thanks Caleb, Great way of breaking it down for better understanding.
regardless this kid looks pretty much high at the beginning of this video I like the way explanation.
Nice and simple
Hi Caleb, you got to go back to the chalk board or white board. These videos are great and love your humor throughout them!
Much love from NC
Your videos are very helpful to me for doing my homework. Thank you!
Hi Caleb, thanks for your videos. V helpful. I'm a bit confused around the difference between Natural and Surrogate key. A natural key is basically a collection of columns that if concatenated would yield unique rows in table, which is effectively the same as adding a unique ID as a proxy for those columns. Wouldn't you always need to know what the natural key would be to establish a surrogate key?
Thanks
+davy Griffiths Hi! You can just add a surrogate 🔑 if you do not have enough data to make a natural one.
Surrogate key is the best! Only limited to the application and it will not deal with the client in real business world
Hey Caleb, awesome video series, really helped me understand the basics of Database management systems.
However... Seriously do you only have t-shirts with stars and stribes?! :D
What was that noise at 3:16?
thank you , very good
Wow, this video has surrogacy ads on it, cause I'm obviously interested in surrogacy lol.
omg, you are so cute. I wish my bf in highschool was as cute as you :P
Very cool video but i thing that you need a little social culture. DB & developering is not all in your live.
Sorry Caleb, at speed 0.5 you are on drug bro. Make me laughs...sorry, I'm out. Keep up the good work
Whaha at 09:05 especially!
Actually you should try . 25
lol
@@sufiyaanrajput7533 😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂😂