0

I have table named Agent. It has attribute named agent_status. It's value can be on or off. I want to conform this table to first normal form. Do i have to create different table for this attribute?

2
  • No need to define a new table. You should have a new table only if the attribute has a repeated value.
    – Renzo
    May 23, 2016 at 7:14
  • 1
    Do you want to track status changes over time? (I.e. will you ever need to query something like "was Agent XYZ status on last Monday at noon?") If yes, then maybe you can benefit from it (there are alternatives), otherwise no. May 23, 2016 at 7:55

1 Answer 1

2

It is better to create a separate table for agent_status. Now it seems easy to add agent_status column in agent table itself. But with my little experience I can tell you, business requirements may change in future, sometime too often. Our data model must be developed in a way it should accommodate all the future requirements and changes without much alteration on the underlying model.

In some cases, business will required to track history of agent_status over a period of time (@Ziggy) and, there are possibilities, where you are required to add new status values, also you may required to change status name in future in order to accommodate your business requirement.

If you are sure that, your business requirement will not change in future, you can add agent_status column in agent table itself, or else create a separate entity named agent_status.

I hope this answer will give you some idea, Thank you.

0

Your Answer

By clicking “Post Your Answer”, you agree to our terms of service and acknowledge that you have read and understand our privacy policy and code of conduct.

Not the answer you're looking for? Browse other questions tagged or ask your own question.