learn-co-curriculum / sql-table-relations-library-lab Goto Github PK
View Code? Open in Web Editor NEWLicense: Other
License: Other
I don't think the last test on the last method is descriptive enough. It talks about the number of books they have appeared in, in descending order but does not mention that names also need to be in ascending order. This is also not reflected in the solution code, which fails to pass the provided test.
Method Description:
def
select_character_names_and_number_of_books_they_are_in
end
Test Description:
it 'selects all of the character names and their number of books they have appeared in, in descending order, grouped by character name'
Failing Solution:
<<-SQL
SELECT characters.name, COUNT(*) as book_count
FROM character_books
JOIN characters
ON character_books.character_id = characters.id
GROUP BY characters.name
ORDER BY book_count DESC
SQL
Passing Solution Suggestion:
<<-SQL
SELECT characters.name, COUNT(*) AS book_count
FROM character_books
JOIN characters
ON character_books.character_id = characters.id
GROUP BY characters.name
ORDER BY book_count DESC, characters.name
SQL
A declarative, efficient, and flexible JavaScript library for building user interfaces.
๐ Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.
TypeScript is a superset of JavaScript that compiles to clean JavaScript output.
An Open Source Machine Learning Framework for Everyone
The Web framework for perfectionists with deadlines.
A PHP framework for web artisans
Bring data to life with SVG, Canvas and HTML. ๐๐๐
JavaScript (JS) is a lightweight interpreted programming language with first-class functions.
Some thing interesting about web. New door for the world.
A server is a program made to process requests and deliver data to clients.
Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.
Some thing interesting about visualization, use data art
Some thing interesting about game, make everyone happy.
We are working to build community through open source technology. NB: members must have two-factor auth.
Open source projects and samples from Microsoft.
Google โค๏ธ Open Source for everyone.
Alibaba Open Source for everyone
Data-Driven Documents codes.
China tencent open source team.