QUESTION 6 Consider the following database schema for a library. Book (BooklD:int, BookTitle:string(unique), Author:string, publisher:string) Borrowing-Record (Bookl D: int, CustomerCPR: int, Date: date, Time: time, Price: double) Customer (CPR:int, name: String) In Borrowing-Record, there are three primary keys? True False
Q: QUESTION 2 Consider the database schema below. Fruit (ID: integer, Name: String (unique)) Vitamin…
A: Two Fruits can't have same name even the Fruit ID is different. Because, Name field is having UNIQUE…
Q: Consider the following relations in the relational schema for a database that keeps track of…
A: Given: Consider the following relations in the relational schema for a database that keeps track of…
Q: Q2/ Consider the relational database of Figure 1. What are the appropriate primary keys? employee…
A: Answer: The Primary Key is used to uniquely identify each record in a table. Primary key cannot have…
Q: QUESTION 3 Consider the following database schema for a library. Book (BookiD:int,…
A: Answer :-- True
Q: For each item below, specify whether the statement is true (T) or false (F). Each…
A: (A)-Each Database Management System (DBMS) is based on a Data Model. Answer-(A) False (B) Database…
Q: Consider the relational database below, where the primary keys are underlined. employee…
A: Given four tables are employee, works, company and manages. The attributes of employee are person…
Q: Consider the following database schema for a library. Book (Book D:int, BookTitle:string(unique),…
A: yes it is possible because for a book author and publisher can be same .... because both contain…
Q: onsider the database schema below for hotels in countries. A country have many hotels, and the same…
A: QUESTION 15 Consider the database schema below for hotels in countries. A country have many…
Q: Consider the relational database of Figure 1. What are the appropriate primary keys? employee…
A: Given query is employee (person_name, street, city) works (person_name, company_name, salary)…
Q: QUESTION 3 Consider the following database schema for a library. Book (BookID:int,…
A: Foreign key :- A foreign key is a set of attributes in a table that refers to the primary key of…
Q: Consider the database schema below for cities in countries. A country have many cities, and the same…
A: Domain Constraint: It specifies that the value taken b the attributes in a relation must contain an…
Q: Given the following relation R and its functional dependencies: R(workerNumber, repairNumber,…
A: Given information: - A relational schema R is: R(workerNumber, repairNumber, workerName,…
Q: Consider the database schema below for cities in countries. A country have many cities, and the same…
A: Given: Consider the database schema below for cities in countries. A country have many cities, and…
Q: QUESTION 4 Consider the following database schema for a library. Book (BooklD:int,…
A: Here is your answer
Q: A QUESTION 6 Consider the following database schema for a library. Book (BookID:int,…
A: The instances in a database schema, as well as their relationships, are described by the schema. It…
Q: QUESTION 5 Consider the database schema below. Fruit (ID: integer, Name: String (unique)) Vitamin…
A: Given: To choose correct option.
Q: Consider the database schema below: Company (ID: integer, Name: String (unique), Address)…
A: We are given two relations and we are asked if there could be same Company name with two different…
Q: QUESTION 2 Consider the following database schema for a library. Book (BookID:int…
A: Entity integrity constraints The entity integrity constraint states that primary key value can't be…
Q: Consider the following relational database that represents books, publishers, and books published by…
A: As per our company guidelines we are supposed to answer ?️only first 3️⃣ sub-parts. Kindly repost…
Q: Consider the database schema below. Fruit (ID: integer, Name: String ) Vitamin (FruitID: Integer.…
A: - We need to select the correct among the provided for the provided relation. - The question is to…
Q: Company (CompnayID: integer, CompnayName: String (unique), address) Department (DepartmentID:…
A: Department is a table with columns DepartmentID of Integer type, DepartmentName of String type and…
Q: QUESTION 3 Consider the database schema below: Company (CompnayID: integer, CompnayName:…
A: Integrity constraint violations occur when an insert, update, or delete statement violates a primary…
Q: Given the following Dentist-patient database schema: Dentist-patient (staffNo, aDate, aTime,…
A: Key for the given relation is (staffNo,aDate,aTime) The functional dependency violating 2NF is…
Q: Give an SQL schema definition for the employee database of Figure 3.19.Choose an appropriate domain…
A: Given: Give an SQL schema definition for the employee database of Figure 3.19.Choose an appropriate…
Q: Q1) B) Consider you have library database, with the following relations: Book(bookID, name, auther,…
A: The correct solution is given below with schema diagram and primary key, foreign keys
Q: QUESTION 5 Consider the database schema below. Fruit (ID: integer. Name: String (unique)) Vitamin…
A: Two tables are given with primary key ID in fruit table. Vitamin table has composite key fruitID…
Q: Answer any IHREE out of the FOUR questions in this section in the answer sheet provided. Each…
A: Relationship between tables: There is M: N relationship between the Trainer table and the Programme…
Q: Consider the following relational database schema that contains information about employees and…
A: {pid,pname} {pid,pname,budget} {pname,managerid} {pname,budget,managerid}
Q: Consider a database with the following relations: Employee (Employee ID, Name, salary, startDate)…
A: The following SQL Query can be broken down into sub-queries: Sub-Query 1: Display Project by name…
Q: Consider the database schema below for hotels in countries. A country have many hotels, and the same…
A: Data Base Management System: DBMS is a software that is used to store, manage and use database…
Q: Consider the following Books database which is used to keep track of books and their readers. Assume…
A: Given:
Q: Consider a database with the following tables: Using sql query or steps Patient(PatientID.…
A: I give the code along with the output screenshot
Q: Consider the Database schema on the relations Courses (Number, Faculty, Course Title, Tutor)…
A: 1) 2) 3)
Q: Student(student Number, StudentName, studentAddress) Book(bookNumber, bookTitle, #authorNumber,…
A: The relational algebra for the given query is as follows,
Q: QUESTION 5 Consider the database schema below: Company (ID: integer, Name: String (unique),…
A: Domain constraints defines valid set of values for an attribute. The data type of domain includes…
Q: er the statement is true (T) or false (F). __ Each Database Management System (DBMS) is…
A: 1. Since Every collection of data handle by either file system or Database Management System (DBMS)…
Q: Suppose a database has the following relations: - ORDER_T (Order_ID, Order_Date, Customer_ID,…
A: Given database consists of three tables Order_T, Product_T, Order_line with some attributes. (a)…
Q: QUESTION 6 Consider the database schema below. Fruit (ID: integer, Name: String (unique)) Vitamin…
A: Given: To choose the correct option.
Q: QUESTION 5 Consider the following database schema for a library. Book (BookID:int,…
A: We have given a dbms tables for Book, Borrowing-Record, Customer. One data member of Book table…
Q: QUESTION 2 Consider the database schema below. Fruit (ID: integer. Name: String (unique)) Vitamin…
A: EXPLANATION: The entity set that is utilized to uniquely identify an entity inside its entity set…
Q: Consider the database schema below for cities in countries. A country have many cities, and the same…
A: Data Base Management System: DBMS is a software that is used to store, manage and use database…
Q: Based on the given primary keys and assuming that Medicine and Contract relations are in 1NF,…
A: Medicine ( Medicine-ID, Medicine-Name, CountryID, CountryName) Here key for the relation is…
Q: Company (CompnayID: integer, CompnayName: String (unique), address) Department (DepartmentID:…
A: Employee is a table with columns ID of integer type, name of String type and DepartmentID of integer…
Q: Consider the following relation: Invoice(Order_ID, Order_Date, Customer_ID,…
A:
Q: Relational Database Consider the following relation: Invoice(Order_ID, Order_Date, Customer_ID,…
A:
Q: Giving the following schema for a supermarket database, specify the domain constrains for each…
A: the answer to the following questions:-
Q: Relational Database Consider the following relation: Invoice(Order_ID, Order_Date, Customer_ID,…
A:
Q: Consider the bank database of Figure 2.18. Assume that branch names and customer names uniquely…
A: Primary key refers to the column or combination of multiple columns which uniquely identify the…
Step by step
Solved in 2 steps
- branch(branchhame, branch+citysassets} customer (HD, Customer name, customer street, customer city) loan loan number branch_name, amounty borrower(ID; loan_number account (account_number, branch name, balance)e depositor (HDs account number)- Figure le Consider the bank database in Figure 1, where the primary keys are underlined. Each branch might have many loans or accounts, associated with borrowers or depositors, respectively. Construct the following SQL queries for this relational database. 1. Find the name of each branch that has at least one customer who has an account in the bank and who lives in the "Harrison" city. Make sure each branch name only appears once. 2. Find the ID of each customer who lives on the same street and in the same city as customer "12345". (1) Please use "tuple variables". e (2) Please use "derived relations" or “with". 3. Find the ID of each customer of the bank who has an account but not a loan. 4. Find the total sum of all loan amounts for each branch…DATABASE: library (library_name [pk], City, Phone, manager_SSN[pk, fk]) book (book_name [pk], Genre, Country) borrower (SSN[pk], Name, Birthyear, Fav book [fk], Gender) likes (SSN[pk, fk], book [pk, fk]) bookLoans (library [fk], books [fk]) manager (SSN[pk], Name, City, Address, Phone) Provide OPTIMIZED relational algebra for the following queries: 1 a) List name, gender, and age of all borrowers. b) List all male borrowers older than 65 years of age. c) List the book names loaned by at least one library and liked by at least one borrower. d) List the name and ssn of all borrowers who like their favorite bookThe following relations kind a part of a on-line database (the relations area unit self-explanatory): CUSTOMER/CLIENT/SHOPPERS/BUYERS(Cust#, CAddress, Ctown, Balance,Cname) ORDER(Order.#, Date, Cust#.) ORDERLINE(Order#, Part#., Amount-Ordered) PART(Part#., Desc, Stock, Item-Class, Unit -Price) Design a physical ER for the above scenario. With respect to this relative schema, write SQL statements for the subsequent queries: List the name of the client United Nations agency has placed Order 123 (i.e. Order: = 123). List the names of shoppers United Nations agency in Cardiff and have ordered half 456 (i.e. Part. 456). List the order numbers (Order) for orders that contain a minimum of three elements and also the quantity ordered are minimum of ten. List the outline (Desc), of these elements that the typical quantity ordered is bigger than the number ordered for half .6 (Part. = 456) so as 123.(Order. .123).
- //Need typed version please You are working with a database that stores information about suppliers, parts and projects. The Supply relation records instances of a Supplier supplying a Part for a Project. The schema for the database used in this question is as follows: ( primary keys are shown underlined, foreign keys in bold). SUPPLIER (SNo, SupplierName, City) PART (PNo, PartName, Weight) PROJECT (JobNo, JobName, StartYear, Country) SUPPLY (SNo, PNo, JobNo, Quantity) Provide relational algebra (NOT SQL) queries to find the following information. NOTE: You can use the symbols s, P, etc or the words ‘PROJECT’, ‘RESTRICT’ etc . do not need to try to make efficient queries – just correct ones. Where you use a join, always show the join condition. List the name of any part that was not used on a project that commenced in 2020. List the name of any part that has been supplied to all projects that commenced in 2020.Database Schema The schema for the Ch07_FACT database is shown below and should be used to answer the next several problems. Click this image to view it in its own tab. FIGURE P7.56 THE CH07_FACT ERD CHECKOUT PATRON PK Check Num PK Pat ID FK1 Book_Num FK2 Pat_ID Check_Out_Date Check_Due_Date Check_In_Date >0-----H- Pat_FName Pat LName Pat_Type BOOK AUTHOR PK Book_Num PK Au ID Book_Title Book_Year Book_Cost Book_Subject FK1 Pat_ID Au_FName Au_LName Au_BirthYear WRITES PK,FK1 Book Num PK,FK2 Au ID The CIS Department at Tiny College maintains the Free Access to Current Technology (FACT) library of e-books. FACT is a collection of current technology e-books for use by faculty and students. Agreements with the publishers allow patrons to electronically check out a book,Veterinarian Office Case: Part 4 The veterinarian office created a database to keep track of owner and pet information. It also includes tracking appointments and treatments for each pet. Unfortunately, the veterinarian database was not created correctly and needs modification. Read the question and select the correct dropdown to answer the question. Owner OWNER_ID OWNER_FNAME OWNER_LNAME OWNER_ST_ADDRESS OWNER_CITY OWNER_STATE OWNERE_POSTAL_CODE OWNER_PHONE OWNER_EMAIL 1 Melissa Canton NULL NULL NV NULL NULL NULL 2 Clay Sheperd Lousetown Road VC Highlands NV 89521 3456789 chsep@gmail.com 3 Helen Harvey 345 Pine Road Reno NV 89521 3451234 hharvey@gmail.com 4 April Windon 123 Doughton Road Reno NV 89521 3454879 awindon@gmail.com 5 Emily Minden 540 Fandango Pass Road VC Highlands NV 89521 3455190 emindn@gmail.com Pet PET_ID PET_BREED PET_NAME OWNER_ID…
- A) The following relations kind a part of a on-line database (the relations area unit self- explanatory): CUSTOMER/CLIENT/SHOPPERS/BUYERS(Cust#, CAddress, Ctown, Balance, Cname) ORDER(Order.# Date, Cust#.) ORDERLINE(Order#, Part#, Amount-Ordered) PART(Part#., Desc, Stock, Item-Class, Unit -Price) a. Design a physical ER for the above scenario. b. With respect to this relative schema, write SQL statements for the subsequent queries: 1. List the name of the client United Nations agency has placed Order 123 (i.e. Order: = 123). 2. List the names of shoppers United Nations agency in Cardiff and have ordered half 456 (i.e. Part. 456). 3. List the order numbers (Order) for orders that contain a minimum of three elements and also the quantity ordered are minimum of ten. 4. List the outline (Desc), of these elements that the typical quantity ordered is bigger than the number ordered for half .6 (Part. = 456) so as 123.(Order..123).Create ERD for Real-estate database: There are Many Cities in each State There are Many Zip Codes in each City Many Houses belong to each ZipCode Each House can be one of HouseTypes ( Town House, Residential, Condo, Single Family) Each House can be Sold multiple times. ( entity Salesstruct student { char name[20]; char studentID[10]; char phonenum [9]; char advisor [20]; float gpa; } Operations needed: addnewStudent { purpose: to create a new student in the database input: name, studentID.phonenum,advisor.gpa output: none } Name another operation besides add that we could use for our student data structure.
- Veterinarian Office Case: Part 5 The veterinarian office created a database to keep track of owner and pet information. It also includes tracking appointments and treatments for each pet. Unfortunately, the veterinarian database was not created correctly and needs modification. Read the question and select the correct dropdown to answer the question. Owner OWNER_ID OWNER_FNAME OWNER_LNAME OWNER_ST_ADDRESS OWNER_CITY OWNER_STATE OWNERE_POSTAL_CODE OWNER_PHONE OWNER_EMAIL 1 Melissa Canton NULL NULL NV NULL NULL NULL 2 Clay Sheperd Lousetown Road VC Highlands NV 89521 3456789 chsep@gmail.com 3 Helen Harvey 345 Pine Road Reno NV 89521 3451234 hharvey@gmail.com 4 April Windon 123 Doughton Road Reno NV 89521 3454879 awindon@gmail.com 5 Emily Minden 540 Fandango Pass Road VC Highlands NV 89521 3455190 emindn@gmail.com Pet PET_ID PET_BREED PET_NAME OWNER_ID…Android question: Suppose you have a table named ‘food’ with the following attributes: Id: int (primary key) name: varchar(20) calories: int cost: float Write a piece of code representing a method in a Dao interface that is part of a Room database implementation. If the method is invoked, all food with ‘calories’ of more than 90 and costs less than 270 must be deleted. Note: suggest a name for your method.Computer Science Design an OO schema for a database application that you are interested in.Construct an EER schema for the application, and then create the corresponding classes in ODL. Specify a number of methods for each class, andthen specify queries in OQL for your database application.