World Cup Database - Build a World Cup Database

Tell us what’s happening:
The World Cup database was working fine until it wasn’t. Half the time I cannot get the virtual server to load. The times I am able to load it, I get this error message " [SUBTASKS 1.1 “before all” hook for “:1 “worldcup” database should exist”]" no matter what I do. I have restarted the whole thing, erased my progress in code ally, and tried using different browsers. nothing is working.

Your code so far

you can view my sql and bash scripts in the link above

Your browser information:

User Agent is: Mozilla/5.0 (Macintosh; Intel Mac OS X 10_15_7) AppleWebKit/605.1.15 (KHTML, like Gecko) Version/16.4 Safari/605.1.15

Challenge: World Cup Database - Build a World Cup Database

Link to the challenge:

Same issue was solved here.

unfortunately this did not work me

The file in your repo is empty (i.e. it’s the boilerplate code).
You have an issue with too.

if [[ -z $WINNER_ID ]]

This doesn’t work as it won’t retrieve the team_id for you. If it’s a valid insertion it will instead return “INSERT 0 1”. You still need to retrieve the value for WINNER_ID after this.

When you run, you get a stream of errors in your terminal because you’re trying to insert “INSERT 0 1” into your database.

The same goes for OPPONENT_ID.

After you have successfully completed and run it, you should see that your database has been populated with the required info.

You should then be able to complete and verify it against the expected output.

The CodeRoad tests will still likely fail because of a timeout issue but there’s an easy workaround for that if it crops up. Let me know if you’re still getting unexpected test fails (e.g. the ‘before all hook’ message), after you’ve fixed/completed your code.