Question: Based on this diagram and tables in it . What sql codes would answer these questions: give me code that would run in sql .
Based on this diagram and tables in it What sql codes would answer these questions: give me code that would run in sql
Give me the number of books published by each author under each publisher?
What is the order number, order date, user, and payment method of the largest checkout cart?
What is our total revenue gained from book purchases?
Give me only those for users aged over with a valid favorite author? Hint: Check if the DOB is after
Give me the total of each checkout cart where the user paid with their membershippoints?
Example question: How many books has each author published?
The code would be:
Select author.firstName, author.lastName countbookauthorid
From author
Inner join book on book.authorid author.authorid
Group by author.authorid
Order by countbookauthorid desc;
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
