8 copy.txt - mysql> Terence Budu-Biney mysql> iste 230...

This preview shows page 1 out of 3 pages.

mysql> # Terence Budu-Biney mysql> # iste 230 mysql> source C:\Users\student\Desktop\budubiney_8.sql -------------- select concat(City,"," " ", S.StateCode) as Location, count(City) as 'Count' from Publisher P, State S where P.StateCode = S.StateCode group by Location -------------- +-------------------+-------+ | Location | Count | +-------------------+-------+ | Boston, MA | 1 | | Chicago, IL | 3 | | Hartford, CT | 1 | | New York, NY | 4 | | Rochester, MN | 1 | | Rochester, NY | 2 | | San Francisco, CA | 1 | +-------------------+-------+ 7 rows in set (0.00 sec) -------------- select title, count(Rating) as 'Total Ratings', min(Rating) as Low, max(Rating) as High, round(avg(Rating),2) as Average from Book b left join BookReview br on b.isbn = br.isbn group by title order by count(Rating) desc, Average desc -------------- +--------------------------------------------------+---------------+------ +------+---------+ | title | Total Ratings | Low | High | Average | +--------------------------------------------------+---------------+------ +------+---------+ | Yes! Networking is for Bills Fans | 3 | 5 | 8 | 6.33 | | The Shortest Book in the World | 2 | 10 | 10 | 10.00 | | My Love's Last Lingering Lost | 2 | 8 | 9 | 8.50 | | From Brockport to IT | 2 | 7 | 10 | 8.50 | | How to Keep your Cellular Bill Down | 2 | 7 | 8 | 7.50 | | Women are From Venus ORACLE is from Beyond Pluto | 1 | 10 | 10 | 10.00 | | My Love's Last Longing | 1 | 10 | 10 | 10.00 | | How to add Class to your Programming | 1 | 9 | 9 | 9.00 | | JAVA: It's more than Just a Programming Language | 1 | 9 | 9 | 9.00 |
Image of page 1
You've reached the end of this preview.
  • Spring '19
  • Jane smith
  • Databases, Relational model, Buffalo Bills

{[ snackBarMessage ]}

What students are saying

  • Left Quote Icon

    As a current student on this bumpy collegiate pathway, I stumbled upon Course Hero, where I can find study resources for nearly all my courses, get online help from tutors 24/7, and even share my old projects, papers, and lecture notes with other students.

    Student Picture

    Kiran Temple University Fox School of Business ‘17, Course Hero Intern

  • Left Quote Icon

    I cannot even describe how much Course Hero helped me this summer. It’s truly become something I can always rely on and help me. In the end, I was not only able to survive summer classes, but I was able to thrive thanks to Course Hero.

    Student Picture

    Dana University of Pennsylvania ‘17, Course Hero Intern

  • Left Quote Icon

    The ability to access any university’s resources through Course Hero proved invaluable in my case. I was behind on Tulane coursework and actually used UCLA’s materials to help me move forward and get everything together on time.

    Student Picture

    Jill Tulane University ‘16, Course Hero Intern