Saturday, March 14, 2015

Date's Twelve Rules for Distributed Database Systems - Local Autonomy


Date's Twelve Rules for Distributed Database Systems - Local Autonomy



1. Local autonomy
  • All operations at a given site are controlled by that site. With local autonomy, each site has the capability to control local data, administer security, and log transactions and recover when local failures occur and to provide full access to local data to local users when any central or coordinating site cannot operate. Data at local sites are owned by that site itself.
  • Local operations remain purely local.
For example, in the figure given below, the database consists of all data stored at Chennai, Mumbai, and New Delhi sites. Actually, the data are distributed and stored at different locations. As we know, database transactions can be handled by Transaction manager component. For the case given below, in a distributed database, the Transaction manager of Chennai site is the owner of data stored at Chennai site, the transaction manager of Mumbai site is the owner of data stored at Mumbai site, and so on.

Distributed database with servers at different locations







Monday, March 9, 2015

Normalization and Functional Dependency - Quiz

Normalization and Functional Dependency - Quiz


1. A relationship R connecting entity sets E and F has referential integrity from E to F, i.e., the edge connecting R and F has an arrow directed towards F. Which of the following statements may be true?
    R is one-one from E to F
    R is many-one from E to F
    Choice 2 only
    Both choices 1 and 2

2. A relation with two attributes A and B satisfies the functional dependency A → B. Then the functional dependency B → A also holds in the relation.
    TRUE
    FALSE

3. A relation R(A,B,C) satisfies the functional dependencies A → B, A → C, and B → A. Then, we can say that R is in BCNF.
    TRUE
    FALSE

4. A relation R(A,B,C) satisfies the functional dependencies A → B, A → C, and B → A. Which of the following are valid candidate keys?
    A
    B
    Both choices 1 and 2
    A alone

5. Which of the following sentences are true??
    4NF implies BCNF
    4NF implies 3NF
    3NF implies 4NF
    Both choices 1 and 2

6. Assume that we have the following four records in a relation R(A, B, C): (1,2,3), (4,2,3), (5,3,3), and (5,3,4). Which of the following FDs does not hold on R?
    BC → A
    B → C
    C → B
    All of the above

7. For a relation R1(A,C,B,D,E), with dependencies A → B, and C → D which of the following is the candidate key?
    {ABC}
    {ACE}
    {ADE}
    {ABE}

8. The closure of set of attributes is said to be a set of ____________.
    Functional Dependencies
    Attributes
    Keys
    Multivalued Attributes

9. {A1, A2, …, An}+ is the set of all attributes of R if and only if A1, A2, …, An is a _______________ for R.
    Prime attribute
    Closure attributes
    Super key
    All of the above

10. Assume that the following set of FDs A → B, B → C, C → A, D → E, E → D are holding on a relation R(A,B,C,D,E). Which of the following sets of tuples satisfy this.
    a1 b1 c1 d1 e1, a1 b1 c1 d2 e2
    a1 b1 c1 d1 e1, a1 b2 c1 d2 e2
    a1 b1 c1 d1 e2, a1 b1 c1 d2 e2
    None of the above

Score =

Correct answers:

Wednesday, March 4, 2015

Codd's Twelve Rules - Rule 12 - Non-Subversion Rule

Codd's Twelve Rules - Rule 12 - Non-Subversion Rule

Rule 12
Non-Subversion Rule
Rule
If the system provides a low-level (record-at-a-time) interface, then that interface cannot be used to subvert the system, for example, bypassing a relational security or integrity constraint.
Description
“This rule states that if a Relational Database Management System has an interface that provides access to low level records, this interface then must not be able to subvert the system and bypass security and integrity constraints.”
“The system must not have features that allow you to subvert database structure integrity. Basically, the system must not include back doors that let you cheat the system for features such as administrative privileges or data constraints.”
“There should be no way to modify the database structure other than through the multiple row database language (like SQL).”
Overall, there should not be a way in any form to violate the integrity constraints defined on a database. Only the language/sublanguage which was used to define those constraints can be able to redefine them. If we would say that a low level language is supported by a RDBMS, then it should not be possible for that low level language to bypass any integrity constraints defined in a high level language.
Example violations of this rule
SQL Server 2008 violates this through Bulk copy and Disabling constraints and triggers options.

Some DBMS that fulfills this property
SQL Server, Oracle


Go to Home - Codd's Twelve Rules


Monday, March 2, 2015

Codd's Twelve Rules - Rule 11 - Distribution Independence

Codd's Twelve Rules - Rule 11 - Distribution Independence Rule



Rule 11
Distribution Independence
Rule
The data manipulation sub-language of a relational DBMS must enable application programs and terminal activities to remain logically unimpaired whether and whenever data are physically centralized or distributed.
Description
The distribution of the parts of any database to different sites/locations should be invisible to the end users. That is, like in distributed database it should give a centralized effect to the end users who access it.
Also, the existing applications are able to continue their operations when the database is distributed or redistributed.
This way of execution provides parallelism in handling transactions.
Example
Oracle
CREATE TABLE sales_hash(salesman_id  NUMBER(5), salesman_name VARCHAR2(30), sales_amount  NUMBER(10), week_no       NUMBER(2)) PARTITION BY HASH(salesman_id) PARTITIONS 4 STORE IN (ts1, ts2, ts3, ts4);
The table sales_hash will be created with 4 partitions on salesman_id values, and partitions will be stored in tablespaces ts1, ts2, ts3, and ts4.
MySQL
CREATE TABLE Emp(Eid INT, EName VARCHAR(30), Salary INT, Dno INT) ENGINE = INNODB PARTITION BY HASH(Dno) PARTITIONS 6;
The above statement creates a table Emp with 6 partitions on Dno attribute values.
Some DBMS that fulfills this property
SQL Server, Oracle, MySQL, IBM DB2


Go to Home - Codd's Twelve Rules



Sunday, March 1, 2015

Advantages of Data Fragmentation in Distributed Database


Advantages of Data Fragmentation / What are the advantages of fragmentation in distributed database management systems?


Advantages of Fragmentation in Distributed Database


  • Parallelized execution of queries by different sites is possible. A query can be divided into several sub-queries and can be executed simultaneously at several sites.
  • A database is fragmented and fragments are made available at different sites. It reduces disk space utilization considerably.
  • Data management is easy as fragments are smaller compare to the complete database.
  • Increased availability of data to the users/queries that are local to the site in which the data stored.

  • Most of the applications work with views rather than entire relations; hence in terms of usage, fragmentation is advantageous.
  • As the data is available close to the place where it is mostly frequently used, the efficiency of the system in terms of query processing, transaction processing is increased.
  • Data that are not required by local applications are not stored locally. It leads to reduced data transfer between sites, and increased security.


Featured Content

Multiple choice questions in Natural Language Processing Home

MCQ in Natural Language Processing, Quiz questions with answers in NLP, Top interview questions in NLP with answers Multiple Choice Que...

All time most popular contents