Oct 23, 2022 05:01 PM
This is probably a stupid question but when designing a table, should the primary key (first column) be unique or not?
In my case, I have Projects and Tasks like
Projects (Fix House, Fix car)
Tasks (Repair bathroom sink, buy new steering wheel, replace lug nuts)
Should the primary key be the Projects or the Tasks? In other words, should the table design look like?
Oct 23, 2022 05:25 PM
In general, it is good practice to have a unique primary field. However, Airtable does not require this.
Note that the primary field (first column) is not the same as a primary key.
If you think that you will have several projects with multiple tasks, you might want to have a two table system, one table for projects and another for tasks. Then join the tables with a linked record field.
Oct 25, 2022 08:10 AM
@kuovonne Thank you. I should have clarified field vs key so thank you for that. What is the advantage to doing a two table system over a one table system? I always thought you’d want fewer tables where possible especially if the (in this case) tasks columns are all unique.
Oct 25, 2022 10:58 AM
Take a look at this support article: