REPLIT Site: https://replit.com/@sqlSylvia/LibrarySystem
- To access and query the InstagramDB replit database, log into replit.com with your username and password. If you don't have one, it is easy create from the replit.com home page.
- Once logged into replit.com, Fork the REPLIT site to your account. This way make a private copy for you to use now and in the future.
REPLIT SQL uses the SQL database SQLLite. As the name implies, it is lightweight version of SQL. You may find some differences between the SQL from the W3Schools SQL Database
- SQLLite Homepage - https://sqlite.org/index.html
- SQLLite SELECT Language - https://www.sqlite.org/lang_select.html
- SQLLite Tutorial - https://www.sqlitetutorial.net/sqlite-show-tables/
Answer the following questions in the form of a SQL query in REPLIT.
-
How many copies of the book titled "The Lost Tribe" are owned by the library branch whose name is "Sharpstown"?
-
How many copies of the book titled "The Lost Tribe" are owned by each library branch?
-
Retrieve the names of all borrowers who do not have any books checked out.
-
For each book that is loaned out from the "Sharpstown" branch and whose DueDate is today, retrieve the book title, the borrower's name, and the borrower's address.
-
For each library branch, retrieve the branch name and the total number of books loaned out from that branch.
-
Retrieve the names, addresses, and number of books checked out for all borrowers who have more than five books checked out.
-
For each book authored by "Stephen King", retrieve the title and the number of copies owned by the library branch whose name is "Central".
