Database [3i Infotech Placement]: Sample Questions 264 - 266 of 294

Glide to success with Doorsteptutor material for competitive exams : get questions, notes, tests, video lectures and more- for all subjects of your exam.

Question 264

Database
Edit

Describe in Detail

Essay▾

What is 1 NF (Normal Form) ?

Explanation

  • The domain of attribute must include only atomic (simple, indivisible) values.

1NF (First Normal Form) Rules

  • Each table cell should contain a single value.
  • Each record needs to be unique.

    1NF Example:

  • Understanding the example of above Normalization table
Table Shows the 1NF Example
Full NamePhysical AddressMOVIES RENTEDSALTUTATION
JanatFirst Street Plot No 4Pirates of the CaribbeanMs.
JanatFirst Street Plot No 4Clash of the TitansMs.
Rohit3rd Street 34Forgetting Sarah MarshalMr.
Rohit3rd Street 34Daddy՚s Little GirlsMr.
Rohit5th AvenueClash of the TitansMr.

Question 265

Database

Question

MCQ▾

A B C is a set of attributes. The functional dependency is a follows:

AB B

AC C

C B

Choices

Choice (4)

a.

Is in 3NF

b.

Is in BCNF

c.

Is in 2NF

d.

Is in 1NF

Answer

d.

Explanation

Table Shows the a, B and C Attributes
{A, B, C}

AC is the primary key

Neither C is a key nor B is a prime attribute

So, it is not 3NF

  • Now, B is not functionally dependent on key AC
  • So, it is not in 2NF
  • Hence, given functional dependency is 1 NF.

Question 266

Database
Edit

Appeared in Year: 2006

Describe in Detail

Essay▾

What is the difference among “dropping a table” “truncating a table” and “deleting all records” from a table?

Explanation

Drop Table

  • It will remove the existence of the table from the database along with its data and structure and all the constraints.
  • The table will be no longer available.
  • This is a DDL Statement.

Truncate Table

  • It will remove all the rows from a table.
  • It will not delete the table. It is a DDL statement that means the deleted rows cannot be reverted back by ROLLBACK statement.
  • It will only be used if users needs to delete the entire rows from a tables.
  • No conditions will be applied in Truncate.

Delete Table

  • It is a DML statement which will delete rows from a table according to the matching criteria mentions in the ‘where’ clause and these rows can be reverted back by ‘ROLLBACK’ statement if ‘COMMIT’ is not fired.
  • Delete statement will used in both the cases, eitehr selected rows or entire rows from tables.

Developed by: