I am designing a database and certain parts of the system that will sit on top of it is the concept of being able to create notes for certain things.
E.g. I have a database of customers and users can create notes for these customers.
There are two styles I can do to achieve this.
The first is to create a notes table and notes type table. All notes for anything i.e. customers, suppliers, invoices etc etc are stored here but differentiated by a typeId which references a type in “notes_type_table”.
Alternatively, I could split out all the notes for different parts of my system. i.e. “customer_notes”, “supplier_notes” and “invoice_notes”.
Similarly to if you wanted to shop for shoes, going to a big superstore that sells shoes and many other things would slow you down due to more traffic (people, queuing etc). Whereas going to a shop that only sells shoes should result in a faster and more efficient process of buying shoes.
Would splitting out note tables for separate parts of my system be better performance wise?
I would go for splitting the information into several tables: