Comment on How does this pic show that Elon Musk doesnt know SQL?

<- View Parent
Barbarian@sh.itjust.works ⁨5⁩ ⁨days⁩ ago

It’s necessary to split it out into different tables if you have a one-to-many relationships. Let’s say you have a list of driver licenses the person has had over the years, for example. Then you’d need the second table. So something like this:

SSN_TABLE

ID | SSN | Other info

Driver_License_Table

ID | SSN_ID | Issue_Date | Expiry_Date | Other_Info

Then you could do something like pull up a person’s latest driver’s license, or list all the ones they had, or pull up the SSN associated with that person.

source
Sort:hotnewtop