Question: ask expert You are working with a database that holds information about a library system. The database includes two tables: Books and Loans . The
ask expert You are working with a database that holds information about a library system. The database includes two tables: Books and Loans The Books table lists every book available in the library, and the Loans table records details about the books currently borrowed by patrons: Books BookID, Title, Author, ISBN, PublicationYear Loans LoanID, BookID, PatronID, LoanDate, DueDate, ReturnedDate Task: Write a SQL query to find all books that have been loaned out at least once this year but are not currently on loan ie no NULL values on the ReturnedDate column Your result should include the ISBN Title Author and the most recent LoanDate for these books. Your solution MUST use the semijoin operator.
Step by Step Solution
There are 3 Steps involved in it
1 Expert Approved Answer
Step: 1 Unlock
Question Has Been Solved by an Expert!
Get step-by-step solutions from verified subject matter experts
Step: 2 Unlock
Step: 3 Unlock
