Relational Algebra Expressions for Relations Publisher, Book and Publish

Consider the following schema of the relational database.

  • Publisher(pid, name, location)
  • Book(bid, title, author, page, price)
  • Publish(bid, pid, publish_date)

 

Write Relational Algebra expressions for the following:

  1. Find title of book published by Addison_wisely.
  2. Update the author name to "MNP" of book "introduction database".
  3. Find the publish date of book "Database Management".

i. Find title of book published by Addison_wisely.

π Book.title ( σ Publisher.name = "Addison_wisely" ( Book Publish Publisher))

 

For explanation, visit this link to a similar question.

 

ii. Update the author name to "MNP" of book "Introduction to Programming".

Temp1 π bid, title, author = "MNP", page, price ( σ title = "introduction database" ( Book ) )

Temp2 σ title ≠ "introduction database" ( Book )

Book Temp1 Temp2

 

OR

Book π bid, title, author = "MNP", page, price ( σ title = "introduction database" ( Book ) ) σ title ≠ "introduction database" ( Book )

 

For explanation, visit this link to a similar question.


iii. Find the publish date of book "Database Management".

π Publish.publish_date ( σ Book.title = "Database Management" ( Book Publish ) )

 

For explanation, visit this link to a similar question.

Asked in Year
2016
Course
BBM
University
TU