4

I have a normalization problem like the following:

R={
    att1(nb1, nb2, nb3),
    att2, val1, val2, def1, class1,
    class2{notion1, notion2},
    def2,col1
  }

Here, attr1 is a multi-valued attribute and class2 is a composite attribute.

How do I convert R to 1NF?

Is it like the following?

R={
    nb1, nb2, nb3,
    att2, val1, val2, def1, class1,
    notion1, notion2,
    def2,col1
  }
philipxy
  • 14,867
  • 6
  • 39
  • 83
user366312
  • 16,949
  • 65
  • 235
  • 452
  • Are nb1, nb2 & nb3 index values? Otherwise how is "multi-valued" different from "composite"? – philipxy Dec 31 '15 at 09:28
  • @philipxy, I don't know. This problem was given in my class. – user366312 Dec 31 '15 at 09:35
  • You should find out because multi-valued usually means homogeneous collection (eg array/list/sequence) & it becomes a single column (and normalization to higher normal forms introduces another table). – philipxy Dec 31 '15 at 19:54
  • Does this answer your question? [Normalization in database management system](https://stackoverflow.com/questions/40623169/normalization-in-database-management-system) – philipxy Feb 08 '22 at 01:30

1 Answers1

3

Yes, your answer is correct. As it is said in Wikipedia:

A relation is in first normal form if the domain of each attribute contains only atomic values, and the value of each attribute contains only a single value from that domain.

In other words, you cannot have attributes that:

  1. are structured, that is contain components, or
  2. are repeated (or both).

So, att1 and class2 must be substituted by their components.

Note that in the result relation you have different rows with the same values for all the other attributes different from nb1, nb2 and nb3.

This normal form has been introduced initially in a paper by E. Codd, in 1971: E. F. Codd, Further normalization of the database relational model, Courant Institute: Prentice-Hall, ISBN 013196741X,

A relation is in first normal form if it has the property that none of its domains has elements which are themselves sets.

(see Wikipedia citation).

This normal form is nowday presented in all the books on relational theory only for historical reasons, since this property is now considered part of the Relational Database Model. See for instance the book Fundamentals of database systems, by R. Elmasri, S. Navathe, Addison Wesley (pag.519 of the 6th edition, ISBN: 978-0-13-608620-8):

First Normal Form

First normal form (1NF) is now considered to be part of the formal definition of a relation in the basic (flat) relational model; historically, it was defined to disallow multivalued attributes, composite attributes, and their combinations. It states that the domain of an attribute must include only atomic (simple, indivisible) values and that the value of any attribute in a tuple must be a single value from the domain of that attribute. Hence, 1NF disallows having a set of values, a tuple of values, or a combination of both as an attribute value for a single tuple. In other words, 1NF disallows relations within relations or relations as attribute values within tuples. The only attribute values permitted by 1NF are single atomic (or indivisible) values.

Community
  • 1
  • 1
Renzo
  • 26,848
  • 5
  • 49
  • 61