I need to design a database table where the columns will be changed on different category: System
, User Input
When the category is System
, the columns are:
id | orderNo | name | category | status
When the category is User Input
, the columns are:
id | orderNo | filename | state_of_charge | capacity | size| resistence | category | status
I have a design in mind, which is to combine all columns into one single table instead of separate to different tables based on category , it is easier for me to do searching(based on category), but my guts feeling is telling me that this design is not pretty, for example, columns will have null values for different category.
Is there any better design?