World Cup Database - Build a World Cup Database

Tell us what’s happening:

SOLVED THERE WAS ONE RESULT WHICH WAS NOT IN THE RIGHT ORDER, I KINDLY ASK FOR FUTURE STUDENTS’ SAKE TO SPECIFY IN THE SPECIFICATIONS IF A CERTAIN ORDER IS NEEDED, THANKS.

Can’t get last check to turn green, even though it looks like the expected output is the same as mine.
The order of the query “List of teams who played in the 2014 ‘Eighth-Final’ round” isn’t the same, so I tried to make ti the same by ordering by name but still no success. Number of decimal digits looks right, I tried restarting and even create a new codespace altogether but no luck. Hope somebody can point me in the right direction, thanks in advance.

###Your project link(s)
My solution and files - ignore universe.sql

My results:

Total number of goals in all games from winning teams:
68

Total number of goals in all games from both teams combined:
90

Average number of goals in all games from the winning teams:
2.1250000000000000

Average number of goals in all games from the winning teams rounded to two decimal places:
2.13

Average number of goals in all games from both teams:
2.8125000000000000

Most goals scored in a single game by one team:
7

Number of games where the winning team scored more than two goals:
6

Winner of the 2018 tournament team name:
France

List of teams who played in the 2014 ‘Eighth-Final’ round:
France
Belgium
Brazil
Colombia
Argentina
Germany
Netherlands
Costa Rica
Uruguay
Switzerland
Mexico
Chile
Nigeria
Algeria
Greece
United States

List of unique winning team names in the whole data set:
Uruguay
Russia
Sweden
Netherlands
Brazil
Germany
Colombia
Argentina
Croatia
England
Belgium
France
Costa Rica

Year and team name of all the champions:
2018|France
2014|Germany

List of teams that start with ‘Co’:
Colombia
Costa Rica

Expected output

Total number of goals in all games from winning teams:
68

Total number of goals in all games from both teams combined:
90

Average number of goals in all games from the winning teams:
2.1250000000000000

Average number of goals in all games from the winning teams rounded to two decimal places:
2.13

Average number of goals in all games from both teams:
2.8125000000000000

Most goals scored in a single game by one team:
7

Number of games where the winning team scored more than two goals:
6

Winner of the 2018 tournament team name:
France

List of teams who played in the 2014 ‘Eighth-Final’ round:
Algeria
Argentina
Belgium
Brazil
Chile
Colombia
Costa Rica
France
Germany
Greece
Mexico
Netherlands
Nigeria
Switzerland
United States
Uruguay

List of unique winning team names in the whole data set:
Argentina
Belgium
Brazil
Colombia
Costa Rica
Croatia
England
France
Germany
Netherlands
Russia
Sweden
Uruguay

Year and team name of all the champions:
2014|Germany
2018|France

List of teams that start with ‘Co’:
Colombia
Costa Rica

Your browser information:

User Agent is: Mozilla/5.0 (Windows NT 10.0; Win64; x64) AppleWebKit/537.36 (KHTML, like Gecko) Chrome/129.0.0.0 Safari/537.36 Edg/129.0.0.0

Challenge Information:

World Cup Database - Build a World Cup Database

Welcome to the forum @davidemazzanti98

Glad you completed the project.

The instructions mention:

Part 3: Query the database
Complete the empty echo commands in the queries.sh file to produce output that matches the expected_output.txt file.

This one got me as well, until the query ordered the lists.

Happy coding

1 Like