Question 290
A product catalog stores optional nested specifications that vary by category but still needs relational constraints. What is the MOST appropriate immediate corrective approach?
Explanation
Correct Answer
Store appropriate semi-structured attributes in a validated JSON column alongside relational keys. This targets the primary issue because JSON storage allows flexible attributes without abandoning structured identity and integrity. Verification: Sample records validate JSON paths while required keys remain enforced. Prevent recurrence: Document a schema contract and version changes to payload format.
Incorrect Answers
Parsing nested arrays into typed rows reduces fragile manual string extraction.
Partitioning is most helpful when queries constrain the partition key.
Aligning the relevant indexes and partition scheme where switching operations require it would not correct a product catalog stores optional nested specifications that vary by category but still needs relational constraints. Store appropriate semi-structured attributes in a validated JSON column alongside relational keys.