Question: User ( UId , Username, Password, Profile, Brief, Joindate) Post ( Code , Title, Details, PublishDate, views, status, type) Comment ( UId, PostCode , Description,
User (UId, Username, Password, Profile, Brief, Joindate)
Post (Code, Title, Details, PublishDate, views, status, type)
Comment (UId, PostCode, Description, commentDate)
Write the corresponding SQL queries for the below questions
- For each post code, list the total number of comments it has.
- Find the post titles having more than 500 views.
- Find the post titles with no comments.
- Find the highest number of views and average number of views of posts.
- List the username and title of post and description of the comment he added.
Step by Step Solution
There are 3 Steps involved in it
Get step-by-step solutions from verified subject matter experts
