I have a database with 200 thousand student records, each student have an extendable profile.
Students is the Primary key table,
StudentProfiles is stores the Profiles elements:
[ProfileID],[StudentID],[PropertyDefinitionID],[PropertyValue]
Each profile contains around 120 Property, so In StudentProfiles i have 200 thousand students * 120 Profile Properties = 24 Million rows.
Some important Profile elements like Count(StudentSiblings) or GuardianEmail are used in many external operations, while the other profile elements are used rarely.
For better performance, Is there any problem if we also saved this 3 or 4 Profile Properties as columns in the master Students Table?
This is just an Example, i also have another case where i want to save the result of an aggregate function for a table in another table for easier and faster access, like storing the Sum of payments for a student in the students table as column, is that kind of Denormalization breaks the DB design standards.
If these frequently used profile elements are atomic – ie each student has only one value for GuardianEmail – then I see no reason why not to store these values in the students table, in the same way that you would store the student’s email or surname in the students table.