Securing Higher Grades Costing Your Pocket? Book Your Assignment at The Lowest Price Now!

The Relational Data Model And Relational Database Constraints Add in library

301 Download2 Pages 457 Words

Questions:

1. Why are tuples in a relation not ordered?

2. Why are duplicate tuples not allowed in a relation?

3. Why do we designate one of the candidate keys of a relation to be the primary key?

4. List the data types that are allowed for SQL attributes.

5. Describe the four clauses in the syntax of a simple SQL retrieval query. Show what type of constructs can be specified in each of the clauses. Which are required and which are optional?

 

 

Answers:

1. A relation is a logical representation of the database. According to the definition, the order of attributes in a relation is important to maintain the corresponds between the between the values to respective attributes. Ordering the tuples in a relation, it will need extra commands and more functionalities. As, ordering of tuple is not necessary and has no impact on physical storage, it is not maintained to save computation resources. (Elmasri, 2008)

2. A relation is a set of ordered tuples, by definition. On the other hand, according to the definition of set, it does not contain duplicate value. Thus, a collection of tuples will be called relation only when there is no duplicates. So, there is no duplicate tuple in a relation. Primary key is used in relations to maintain this property. (Elmasri, 2008)

3. Candidate key can uniquely identify a tuple from a relation. Any candidate key can do the same task. On the other hand primary key is a candidate key that is designated as the same for a relation. There are other use of primary key, for example, in referencing to the foreign key, indexing to support searching etc. If there is two or more designated primary key, then referencing, indexing etc. will be problematic, more computational resources will be consumed to maintain properties of primary key for both. So, it is not used in practice. (Elmasri, 2008)
 
4. The data types available for SQL attributes are, numeric, bit string, character string, Boolean, Date and Time. The list is,
  1. Data Types
    1. Numeric
      1. INT
      2. SMALLINT
  • FLOAT
  1. REAL
  2. DOUBLE PRECISION
  3. DECIMAL(i,j)
  1. Bit String
    1. BIT(n)
    2. BIT VARYING(n)
  2. Character String
    1. CHAR(n)
    2. VARCHAR(n)
  • CLOB()
  1. Boolean
  2. Date
  3. Time
5. The Four clause in syntax of a simple SQL query are,
  • SELECT is a required clause. This is used for selecting the attributes of a relation.
  • FROM is a required clause. This is used for selecting the tuples of a relation.
  • WHERE is an optional clause. It is used to retrieve some tuples that satisfies the condition with the WHERE clause in the SQL query.
  • ORDER BY is an optional clause. It is used to order the results from the SQL query in ascending or descending order.

 

 

References

Elmasri, R. (2008). Fundamentals of Database Systems (6th ed.). Pearson.

OR

For years, MyAssignmenthelp.com has been operating as one of the cheap assignment help providers in the USA. We are one of the best college paper writing services that keep service price minimal. We do not let the affordability of our service to hamper the standard of our work. We have separate teams of experts to provide report writing help . At MyAssigenmnthelp.com, we believe in earning credibility, so students can pay for assignments only after getting satisfied solutions. Tough assignments bother you? Trust us with your project. You will not regret paying us to write assignments for you.

Most Downloaded Sample of Management

271 Download1 Pages 48 Words

Toulin Method Of Argumentation

You are required to write a researched argument essay that convinces persuades the reader of your position / stance. This is an academic, researched and referenced do...

Read More Tags: Australia Arlington Management Management University of New South Wales Management 
202 Download9 Pages 2,237 Words

Consumer Behavior Assignment

Executive Summary The purpose of this report is to elaborate the factors which are considered by individuals before selecting an occupation. Choosing an occupati...

Read More Tags: Australia Arlington Management Management University of New South Wales Management 
367 Download13 Pages 3,112 Words

Internet Marketing Plan For River Island

Introduction With the increase enhancement in the field of technology, it has been considered essential by the businesses to implement such technology in their b...

Read More Tags: Australia Arlington Management Management University of New South Wales Management 
325 Download9 Pages 2,203 Words

Strategic Role Of HR In Mergers & Acquisitions

Executive Summary In a merger & acquisition, role of an HR has emerged as a very critical function. At each stage of merger and acquisition process, HR plays a s...

Read More Tags: Australia Arlington Management Management University of New South Wales Management 
353 Download7 Pages 1,521 Words

Relationship Between Knowledge Management, Organization Learning And HRM

Introduction In this competitive business environment where every business organization is trying to attract the customers of each other, it becomes essential for ...

Read More Tags: Australia Arlington Management Management University of New South Wales Management 
Next
Free plagiarismFree plagiarism check online on mobile
Have any Query?