Sign Up

Sign Up to our social questions and Answers Engine to ask questions, answer people’s questions, and connect with other people.

Have an account? Sign In

Have an account? Sign In Now

Sign In

Login to our social questions & Answers Engine to ask questions answer people’s questions & connect with other people.

Sign Up Here

Forgot Password?

Don't have account, Sign Up Here

Forgot Password

Lost your password? Please enter your email address. You will receive a link and will create a new password via email.

Have an account? Sign In Now

You must login to ask a question.

Forgot Password?

Need An Account, Sign Up Here

Please briefly explain why you feel this question should be reported.

Please briefly explain why you feel this answer should be reported.

Please briefly explain why you feel this user should be reported.

Sign InSign Up

The Archive Base

The Archive Base Logo The Archive Base Logo

The Archive Base Navigation

  • SEARCH
  • Home
  • About Us
  • Blog
  • Contact Us
Search
Ask A Question

Mobile menu

Close
Ask a Question
  • Home
  • Add group
  • Groups page
  • Feed
  • User Profile
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Buy Points
  • Users
  • Help
  • Buy Theme
  • SEARCH
Home/ Questions/Q 9008951
In Process

The Archive Base Latest Questions

Editorial Team
  • 0
Editorial Team
Asked: June 16, 20262026-06-16T02:04:15+00:00 2026-06-16T02:04:15+00:00

How far does one go to eliminate duplicate data in a database? Because you

  • 0

How far does one go to eliminate duplicate data in a database? Because you could go OTT and it would get crazy. Let me give you an example…

If I were to create a Zoo database which contains a table ‘Animal’ which has a ‘name’, ‘species’ and ‘country_of_birth’

But there will be duplicate data there as many animals could come from same country and there could be lots of tigers, for example.

So really there should be a ‘Species’ table and a ‘Country_of_birth’ table
But then after a while you would have tons of tables
So how far do you go?

In this question I am just using one table as an example. One row in the Animal table stores information about a single animal in the zoo. So that animal’s name, species and country of birth, as well as a unique animalID.

  • 1 1 Answer
  • 0 Views
  • 0 Followers
  • 0
Share
  • Facebook
  • Report

Leave an answer
Cancel reply

You must login to add an answer.

Forgot Password?

Need An Account, Sign Up Here

1 Answer

  • Voted
  • Oldest
  • Recent
  • Random
  1. Editorial Team
    Editorial Team
    2026-06-16T02:04:17+00:00Added an answer on June 16, 2026 at 2:04 am

    But there will be duplicate data there as many animals could come from
    same country and there could be lots of tigers, for example.

    This suggests you want to keep track of individual animals, not just kinds of animals. Let’s assume that the zoos use some kind of numeric tattoo or microchip to identify individual animals.

    Assume this sample data is representative. (It’s not, but it’s ok for teaching.)

    Animals
    Predicate: Animal having microchip <chip_num> of species <species> 
               has name <name> and was born in <birth_country_code>.
    
    chip_num  name       species          birth_country_code
    --
    101234    Anita      Panthera tigris  USA
    101235    Bella      Panthera tigris  USA
    101236    Calla      Panthera tigris  USA
    101237    Dingo      Canis lupus      CAN
    101238    Exeter     Canis lupus      CAN
    101239    Bella      Canis lupus      USA
    101240    Bella      Canis lupus      CAN
    

    There’s no redundant data in that table. None of those columns can be dropped without radically changing the meaning of that table. It has a single candidate key: chip_num. It’s in 5NF.

    Values are repeated in non-key columns. That’s kind of the definition of non-key (non-prime) columns. Values in key columns (or sets of key columns) are unique; values in non-key columns aren’t.

    If you want to restrict the values in “birth_country_code” to the valid three-letter ISO country codes, you can add a table of valid three-letter ISO country codes, and set a foreign key reference to it. This is generally a Good Thing, but it has nothing to do with normalization.

    iso_country_code
    --
    CAN      
    USA
    

    You could do the same thing again for “species”. That, too, would generally be a Good Thing, and it, too, would have nothing to do with normalization.

    • 0
    • Reply
    • Share
      Share
      • Share on Facebook
      • Share on Twitter
      • Share on LinkedIn
      • Share on WhatsApp
      • Report

Sidebar

Related Questions

In Silverlight, how does one get row data from a DataGrid that is full
This is very strange because as far as I can tell the method does
I'm trying to get my rendering-to-texture working. So far, it does all the necessary
I'm writing a database front-end that so far relies on a data access layer
How does one access data imported from a CSV file by using dynamic note
How does one return unescaped Json, using Json.Net in an MVC project? So far,
How does one write a language? I really can't imagine how this would be
As far as I know, memcached runs in-memory and does not have a persistent
Does anyone know why the STL containers don't have virtual destructors? As far as
As far as I know, the multi-core architecture in a processor does not effect

Explore

  • Home
  • Add group
  • Groups page
  • Communities
  • Questions
    • New Questions
    • Trending Questions
    • Must read Questions
    • Hot Questions
  • Polls
  • Tags
  • Badges
  • Users
  • Help
  • SEARCH

Footer

© 2021 The Archive Base. All Rights Reserved
With Love by The Archive Base

Insert/edit link

Enter the destination URL

Or link to existing content

    No search term specified. Showing recent items. Search or use up and down arrow keys to select an item.