How might you check to ensure dates are entered correctly

Assignment Help Database Management System
Reference no: EM13945269

What you see below is an Entity Relationship Diagram, or ERD, of a very small Human Resources (HR) database schema. The 7 tables you see represent entities that have various relations with one another.

The bolded text is the name of the entity (table), while the purple text represents the primary key. You will notice that most of the entries in purple text end in _id with one exception in the JOB_HISTORY table.

I would like you to take this HR schema and create a database in MySQL from it using appropriate data types, appropriate database engine, setting up primary and foreign keys (remember, foreign keys require a certain MySQL database engine), etc. Call your database HR, just as you see below.

As you can see in this sample schema, each block represents an entity or table as we call it, once it reaches our database. The black BOLDED text represents the name of the table. The entries under the name represent the various fields (columns), while the purple entries represent primary keys. Some of the tables have a single relationship with another table, while others have relationships with multiple tables.

You'll also notice that there are a number of column names that end in "_id", but are not the purple colored primary keys for the table. If you look, almost every one of these point to a primary key in another table, making them foreign keys. You'll also notice a particularly strange relationship that has the EMPLOYEES table relating back to itself.

Questions to Answer

1) There are actually three types of keys in the JOB_HISTORY table. What are those three types of keys? Remember that some keys can actually be of more than one type.

3) You'll notice a strange relationship that the EMPLOYEES table has back to itself. This is known as a recursive relationship. Looking at the fields in EMPLOYEES, why would this table have a relationship back to itself?

5) This version of MySQL doesn't implement check constraints. With that in mind, how might you check to ensure dates are entered correctly? For example, that the start_date is prior to the end_date in the JOB_HISTORY table?

Reference no: EM13945269

Questions Cloud

Introduces online presence for business : Module 4 introduces online presence for business and information security policies. E-commerce can result in a radical change in the manner business operate, but it needs to be integrated with the rest of the business. Some of the integration include..
The car move while accelerating : A car enters the freeway with a speed of 40km/h and accelerates to a speed of 92km/h in 3.5 minutes. How far does the car move while accelerating?
Mutual fund with an expected return : You own a mutual fund with an expected return of 10% per year and a standard deviation of returns of 12% per year. You are considering adding another stock to your portfolio. The new stock has an expected return of 10% per year and a standard deviati..
What were the chalcedonian doctrine and its alternatives : What was the major question addressed by the Council of Nicea and what were the Nicene doctrine and its alternatives ? What was the major question addressed by the Council of Chalcedon,and what were the Chalcedonian doctrine and its alternatives? ..
How might you check to ensure dates are entered correctly : This version of MySQL doesn't implement check constraints. With that in mind, how might you check to ensure dates are entered correctly?
Elements of the employee value proposition : Why is it important to understand thoroughly the various elements of the employee value proposition (EVP)? - Why would a company want to know what are the most important aspects of EVP for their employees?
Arranged in close proximity to one another : Two coils are arranged in close proximity to one another. The first coil is connected to a Duracell battery. Explain what, if any, effect this has on the second coil. Use an electromagnetism principle to justify your answer.
Write paper on people group history and cultural background : My thesis statement is: Despite the widespread acceptance of Christianity, the unreached people the Swahili of Uganda are still less than 2% evangelical and are in need of being reached with the gospel.
Honda uses collaboration s/w to speed product development : Why did Honda resort to a software package to support this critical business process rather than develop a custom application to meet its needs

Reviews

Write a Review

Database Management System Questions & Answers

  Knowledge and data warehousing

Design a dimensional model for analysing Purchases for Adventure Works Cycles and implement it as cubes using SQL Server Analysis Services. The AdventureWorks OLTP sample database is the data source for you BI analysis.

  Design a database schema

Design a Database schema

  Entity-relationship diagram

Create an entity-relationship diagram and design accompanying table layout using sound relational modeling practices and concepts.

  Implement a database of courses and students for a school

Implement a database of courses and students for a school.

  Prepare the e-r diagram for the movie database

Energy in the home, personal energy use and home energy efficiency and Efficient use of ‘waste' heat and renewable heat sources

  Design relation schemas for the entire database

Design relation schemas for the entire database.

  Prepare the relational schema for database

Prepare the relational schema for database

  Data modeling and normalization

Data Modeling and Normalization

  Use cases perform a requirements analysis for the case study

Use Cases Perform a requirements analysis for the Case Study

  Knowledge and data warehousing

Knowledge and Data Warehousing

  Stack and queue data structure

Identify and explain the differences between a stack and a queue data structure

  Practice on topic of normalization

Practice on topic of Normalization

Free Assignment Quote

Assured A++ Grade

Get guaranteed satisfaction & time on delivery in every assignment order you paid with us! We ensure premium quality solution document along with free turntin report!

All rights reserved! Copyrights ©2019-2020 ExpertsMind IT Educational Pvt Ltd