Your Tasks
Last updated
Last updated
For this assignment you will get acquainted with running RookieDB's command line interface and make a small change to one file to get things working properly.
Most databases provide a command line interface (CLI) to send and view the results of queries. To run the CLI in IntelliJ navigate to the file:
src/main/java/edu/berkeley/cs186/database/cli/CommandLineInterface
It's okay if you don't understand most of the code here right now, we just want to run it. Locate the arrow next to the class declaration click on it to start the CLI.
This should open a new panel in IntelliJ resembling the following image:
Click on this panel and try typing in the following query and hitting enter:
SELECT * FROM Courses LIMIT 5;
You should get something similar to the following output:
Hmm, that doesn't look quite right! Follow the instructions in the next task to get the proper output. To exit the CLI just type in exit
and hit enter.
Open up src/main/java/edu/berkeley/cs186/database/databox/StringDataBox.java
. It's okay if you do not understand most of the code right now.
The toString
method currently looks like:
Follow the instructions in the TODO(proj0)
comment to fix the return statement.
Navigate tosrc/test/java/edu/berkeley/cs186/database/databox/TestWelcome.java
and try running the test in the file, which should now be passing. Now you can run through Task 1 again to see what the proper output should be.
Follow the instructions in the next section "Submitting the Assignment" to turn in your work.