Define ssn of salesman by using database of business trips, Database Management System

Assignment Help:

Consider the subsequent relations for a database which keeps track of business trips of salespersons in a sales office:
SALESPERSON (SSN, Name, start_year, Dept_no)
TRIP (SSN, From_city, To_city, Departure_Date, Return_Date, Trip_ID)
EXPENSE(TripID, Account#, Amount)
Specify the subsequent queries in relational algebra:
(i) Give the details (all attributes of TRIP) for trips which exceeded $2000 in expenses.
(ii) Print the SSN of salesman who took trips to ‘Honolulu'
(iii) Print the trip expenses incurred through the salesman with SSN= ‘234-56-7890'.Note in which the salesman might have gone on more than one trip. List them individually

Ans: (i) πTRIP.* (σ amount > 2000 (TRIP EXPENSE))
(ii) π SSN (σ to_city = ‘Honolulu' (TRIP))
(iii) πEXPENSE.tripid, amount (σ SSN = ‘234-56-7890' (TRIP EXPENSE))


Related Discussions:- Define ssn of salesman by using database of business trips

Er schema can be represented by relation schemas , Q. Describe how an ER sc...

Q. Describe how an ER schema can be represented by relation schemas and constraints arising from ER design can be mapped to constraints on a relation schema.     The entity rela

What is an e-r model and draw an e-r diagram for the company, What is an E-...

What is an E-R model? Draw an E-R Diagram for the company database with following Descriptions? The company is organized within departments. Each department has a unique name a

Define the one-way associations, One-way Associations When an associat...

One-way Associations When an association is traversed only in the one direction, then it is implemented as a pointer i.e.an attribute which contains an object reference. If mu

Explain differance between primary and secondary storage, Explain differanc...

Explain differance between Primary and secondary storage ? Primary and secondary storage Computer storage is classified within primary(main) memory and secondary(per

Database Normalization, I have a homework assignment due today by midnight....

I have a homework assignment due today by midnight. I need help understanding databasse normalization and determining the type of form violation & how to fix the violation.

Keys - relational database integrity, Candidate Key:  In a relation R, a ca...

Candidate Key:  In a relation R, a candidate key for R is a subset of the set of attributes of R, which have the differnt two properties: (1)        Uniqueness:                N

Modify - referential integrity, Update or Modify operation alters the exist...

Update or Modify operation alters the existing values. If these operations alter the value that is the foreign key also, the only check need is the similar as that of the Insert op

Construct an er diagram for a hospital, Construct an ER diagram for a hospi...

Construct an ER diagram for a hospital along with a set of patients and a set of medical doctors Associate with every patient a log of the several tests and examinations conducted.

What is system log, What is system log?  What are the entries?       An...

What is system log?  What are the entries?       Ans:  The system log that is generally written on stable storage contains the redundant data required to recover from volatile

What is relational model feature, What is relational model feature? A r...

What is relational model feature? A relational model feature is much more data independence than some other database models.

Write Your Message!

Captcha
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