Write appropriate SQL DDL statements for declaring the LIBRARY relational database schema below. Specify the keys, the referential integrity, and the check constraints
that may apply. Use SQL DML statements to populate the database with 5 rows in each table, and then implement the following requests:
1. List the books published by a given publisher (specified by name) in alphabetical order of their titles
2. List all the borrowers living in Baltimore in descending order of their phone numbers
3. List the books with a title starting or ending with the letter 'A'
Submit the SQL statements as a text file (Notepad) following the document naming convention FirstnameLastnameHW1.txt.
Grading: this homework is awarded 100 points (40 points for creating the tables with all the required constraints, 30 points for populating the tables correctly, and 10
points for each of the 3 requests).
This material may consist of step-by-step explanations on how to solve a problem or examples of proper writing, including the use of citations, references, bibliographies, and formatting. This material is made available for the sole purpose of studying and learning - misuse is strictly forbidden.
CREATE TABLE PUBLISHER
( NAME VARCHAR(20) NOT NULL ,
CONSTRAINT PUBLISHER_PK PRIMARY KEY (NAME)
CREATE TABLE BORROWER
( CARD_NO NUMBER NOT NULL ,
CONSTRAINT BORROWER_PK PRIMARY KEY (CARD_NO)
CREATE TABLE BOOK
( BOOK_ID NUMBER NOT NULL ,
CONSTRAINT BOOK_PK PRIMARY KEY (BOOK_ID)
CONSTRAINT BOOK_FK1 FOREIGN KEY (PUBLISHER_NAME)
REFERENCES PUBLISHER (NAME)
CREATE TABLE BOOK_AUTHOR...