Simple 'issue' here, but my OCD is causing me conflicts as to the the best choice...
I have a simple table that gets new records inserted when email replies come into a system. It simply records a timestamp and the database record to which the reply applies.
There is a requirement to add functionality to highlight that there is a new/unacknowledged email (which gets acknowledged when the record to which the email relates is view by a user).
Now, I'm thinking a simple, new bit value against the record to record its "new" status which gets cleared when the parent record is viewed.
But then the little voice kicks in and says that it's a waste of a new field (even though its only a bit) since once acknowledged I'm still storing 0's against every record for no purpose whatsoever - I could simply record the parent id as a negative value initially and update to positive when acknowledged, thereby saving the "expense" of adding a new field that provides no real benefit after the fact.
Another voice chimes in to say simply create a second table that purely holds the id's of records that are "new" and delete the record when its acknowledged, thereby no waste of data recorded.
What do I go with:
1. New field to hold the "new" status.
2. Use the existing recordid field but record new records temporarily as negative values.
3. New table to temporarily hold the new status of records.
I have a simple table that gets new records inserted when email replies come into a system. It simply records a timestamp and the database record to which the reply applies.
There is a requirement to add functionality to highlight that there is a new/unacknowledged email (which gets acknowledged when the record to which the email relates is view by a user).
Now, I'm thinking a simple, new bit value against the record to record its "new" status which gets cleared when the parent record is viewed.
But then the little voice kicks in and says that it's a waste of a new field (even though its only a bit) since once acknowledged I'm still storing 0's against every record for no purpose whatsoever - I could simply record the parent id as a negative value initially and update to positive when acknowledged, thereby saving the "expense" of adding a new field that provides no real benefit after the fact.
Another voice chimes in to say simply create a second table that purely holds the id's of records that are "new" and delete the record when its acknowledged, thereby no waste of data recorded.
What do I go with:
1. New field to hold the "new" status.
2. Use the existing recordid field but record new records temporarily as negative values.
3. New table to temporarily hold the new status of records.