COMP3311 23T1 Assignment 1
Submitting Your Assignment
Database Systems
Last updated: Wednesday 1st March 6:03pm
Most recent changes are shown in red ... older changes are shown in brown.

[Assignment Spec]  [Database Design]  [Examples]  [Testing]  [Submitting]  [Fixes+Updates]


Definition: in the instructions below, the phrase "CSE server" refers to any of the general login/Vlab servers (e.g. vx02, vx05 but NOT vxdb2).
You can store your ass1.sql file, in your home directory, on any of these servers. But you can only run PostgreSQL on vxdb2 or your local machine.

How you submit your assignment depends on where your ass1.sql file is located.

If your ass1.sql is on your home machine and if you are supremely confident that it will work ok on the CSE servers, then the easiest way to submit is via Webcms3.

If your ass1.sql is on your home machine and if you are sensible, you will first copy your ass1.sql file to a CSE server, test it there, and then submit via the give command:

give cs3311 ass1 ass1.sql

Do NOT run give on vxdb2. It may not work and not submit your files.

Testing your code involves interacting with two servers: vxdb2 and any CSE server. The code files, however should only be placed on a CSE server.

Here's a suggestion for managing your work:

# on a CSE server
vlab$ mkdir  -p  /home/$USER/cs3311/ass1
vlab$ cd /home/$USER/cs3311/ass1
# create your ass1.sql file here
vlab$ vi ass1.sql   # or your favourite editor

# on the vxdb2 server
vxdb2$ source /localstorage/$USER/env
vxdb2$ p1   #  run your PostgreSQL server
vxdb2$ cd /home/$USER/cs3311/ass1

# if you don't already have an ass1 database
vxdb2$ createdb ass1
vxdb2$ psql ass1 -f /home/cs3311/web/23T1/assignments/ass1/ass1.dump

# load your code
vxdb2$ psql ass1 -f ass1.sql

# do some manual testing via e.g. select * from q1;
vxdb2$ psql ass1

# automated tests TBA

Repeat the last few steps (from load your code on) until either check_all() says "correct" for all the test cases, or until you give up trying to fix the ones that aren't correct.

Then submit you work using give as above.

After submissions have closed, we will test your work like this:

# drop any old database and make a new one
vxdb2$ dropdb ass1
vxdb2$ createdb ass1

# load the data you were given
vxdb2$ psql ass1 -f /home/cs3311/web/23T1/assignments/ass1/ass1.dump

# load your code
vxdb2$ psql ass1 -f /Your/Submitted/ass1.sql

# run automated testing

# check the results file for number correct

# drop any old database and make a new one
vxdb2$ dropdb ass1
vxdb2$ createdb ass1

# load new data you havn't seen
vxdb2$ psql ass1 -f /home/cs3311/web/23T1/assignments/ass1/ass1.dump2

# load your code
vxdb2$ psql ass1 -f /Your/Submitted/ass1.sql

# run automated testing

After doing this, run the auto-testing.