on 20 comments

Types of attributes in DBMS with example

Entities are represented by means of their properties, called attributes. Attributes are characteristics of an entity. An entity may have many attributes. For each attribute, there is set permitted values called domain

Types of Attributes

ATOMIC ATTRIBUTE

An attribute that cannot be divided into smaller independent attribute is known as atomic attribute.

For example, assume Student is an entity and its attributes are Name, Age, Address and Phone no. Here the age (attribute) of student (entity) cannot further divide. In this example age is atomic attribute.

COMPOSITE ATTRIBUTE

An attribute that can be divided into smaller independent attribute is known as composite attribute.

For example, assume Student is an entity and its attributes are Name, Age, Address and Phone no. Here the address (attribute) of student (entity) can be further divide into House no, city and so on. In this example address is atomic attribute.

SINGLE VALUED ATTRIBUTE

An attribute that has only single value for an entity is known as single valued attribute.

For example, assume Student is an entity and its attributes are Name, Age, Address and Phone no. Here the age (attribute) of student (entity) can have only one value. Here, age is single valued attribute.

MULTI VALUED ATTRIBUTE

An attribute that can have multiple values for an entity is known as multi valued attribute.

For example, assume Student is an entity and its attributes are Name, Age, Address and Phone no. Here the Phone no (attribute) of student (entity) can have multiple value because a student may have many phone numbers. Here, Phone no is multi valued attribute.

STORED ATTRIBUTE

An attribute that cannot be derived from another attribute is known as stored attribute.

For example, birth date cannot derive from age of student.

DERIVED ATTRIBUTE

An attribute that can be derived from another attribute is known as derived attribute.

For example, age can be derived from birth date of student.

NULL VALUED ATTRIBUTE

An attribute, which has not any value for an entity is known as null valued attribute.

For example, assume Student is an entity and its attributes are Name, Age, Address and Phone no. There may be chance when a student has no phone no. In that case, phone no is called null valued attributes.

KEY ATTRIBUTE

An attribute that has unique value of each entity is known as key attribute.


For example, every student has unique roll no. Here roll no is key attribute.

20 comments:

  1. The example of derived attribute is wrong

    ReplyDelete
  2. Example of derived value is age can derived from birthdate

    ReplyDelete
  3. In derived attribute age can be derived from birth date

    ReplyDelete
    Replies
    1. But birth date cannot be derived from age

      Delete
  4. Check composite attribute's last line

    ReplyDelete
  5. Very nice notes,check on derived attribute.otherwise the others are correct and understandable.nice examples too.

    ReplyDelete
  6. Derived attribute example is wrong

    ReplyDelete
  7. Er diagrams allows attributes to be assigned on relationships so what is the name of that attribute ?

    ReplyDelete
  8. change atomic to composite in composite attribute last line

    ReplyDelete
  9. Why 'Key Attribute' is all covered in white colour?? 🤔

    ReplyDelete