Search code examples
sqldatabasedata-modelingerd

SQL Single Column Table


I have a model where a Shipment can have many Products through a product_shipments lookup table.
The Shipment model also has a relationship where a shipment can have one to many bill_of_lading numbers.

Is it proper to create a new table for just one bill_of_lading field ? Most cases a shipment will have only one bill_of_lading number, but often a shipment will contain 2 or more.

There are no other attributes for a bill_of_lading that need to be tracked other than just the number.

What is the proper way to handle this case? Normalization rules would suggest pulling this out into its own table , correct ?


Solution

  • Yes, I would suggest you to do the same thing as you did with Shipment and Products, i.e. create new table. It is a proper way of doing it and easier for you to query later on and even altering your table structure should you need to.