COMP3311 Course Overview

COMP3311 23T3 ♢ Overview ♢ [0/27]

COMP3311 Database Systems

[Diagram:Pics/intro/pgsql.jpg]

Lecturer: John Shepherd   (cs3311@cse.unsw.edu.au)
Course Admin: Dylan Brotherston   (cs3311@cse.unsw.edu.au)
Web Site: http://webcms3.cse.unsw.edu.au/COMP3311/23T3/
or   http://www.cse.unsw.edu.au/~cs3311/

(If Webcms3 is unavailable, try http://www.cse.unsw.edu.au/~cs3311/23T3/)

COMP3311 23T3 ♢ Overview ♢ [1/27]
❖ Why Study Databases?

Every significant computer application involves Large Data.

This needs to be:

Green stuff handled by databases;   blue by networks.

Challenges in building effective databases: efficiency, security, scalability, maintainability, availability, integration, new media types (e.g., music), ...

COMP3311 23T3 ♢ Overview ♢ [2/27]
❖ Databases: Important Themes

The field of databases deals with:

COMP3311 23T3 ♢ Overview ♢ [3/27]
❖ What is Data? What is a Database?

According to the Elmasri/Navathe textbook ...

COMP3311 23T3 ♢ Overview ♢ [4/27]
❖ Studying Databases in CSE

COMP3311 introduces foundations & technology of databases


After COMP3311 you can go on to study ...

COMP3311 23T3 ♢ Overview ♢ [5/27]
❖ Syllabus Overview

Core syllabus ...


The brown stuff is not covered in tutes/pracs and is not examinable
COMP3311 23T3 ♢ Overview ♢ [6/27]
❖ Syllabus Overview (cont)

More syllabus ...


Blue and green stuff is covered only briefly, and is not examinable

To learn more about the green stuff, take COMP9313, ...

To learn more about the blue stuff, take COMP9315, ...

COMP3311 23T3 ♢ Overview ♢ [7/27]
❖ Your Background

We assume that you ...


You might have acquired this background in
If you don't know Python, look at some online tutorials soon.

e.g. https://www.python.org/about/gettingstarted/

COMP3311 23T3 ♢ Overview ♢ [8/27]
❖ Teaching/Learning

Stuff that is available for you:

COMP3311 23T3 ♢ Overview ♢ [9/27]
❖ Teaching/Learning (cont)

On the course website, you can:

URL: https://webcms3.cse.unsw.edu.au/COMP3311/23T3/

(If Webcms3 is unavailable, try http://www.cse.unsw.edu.au/~cs3311/23T3/)

COMP3311 23T3 ♢ Overview ♢ [10/27]
❖ Lectures

2-hour live lectures on Monday 2-4, Wednesday 11-1

Lectures will be recorded but not live-streamed

Different lecture enrolments

Note: CLB-7 holds ~450 students, course has ~700 students
COMP3311 23T3 ♢ Overview ♢ [11/27]
❖ Assignments

Two assignments, which are critical for learning

  1. SQL/PLpgSQL, 12%, due end week 5, beer database
  2. Python/SQL/psycopg2, 16%, due end week 9, ???? database
All assignments are done individually, and ...
COMP3311 23T3 ♢ Overview ♢ [12/27]
❖ Quizzes

Six quizzes, each worth 4 marks

COMP3311 23T3 ♢ Overview ♢ [13/27]
❖ Quizzes (cont)

Marking

If you have special consideration for a quiz
COMP3311 23T3 ♢ Overview ♢ [14/27]
❖ Exam

The Final Exam includes questions on ...

In-lab, closed-book, invigilated exam exam during exam period

You must take the exam in the labs; no online exams.

Sample exam will be available on the course website in Week 10

COMP3311 23T3 ♢ Overview ♢ [15/27]
❖ Supplementary Assessment Policy

Everyone gets exactly one chance to pass the Exam

If you attempt the Exam

All Special Consideration requests: Supplementary Exams are held ... in O-week 24T1.

We assume you'll be back from holidays by O-week.

COMP3311 23T3 ♢ Overview ♢ [16/27]
❖ Assessment Summary

Your final mark/grade will be determined as follows:

quizzes = mark for on-line quizzes   (out of 12)
ass1    = mark for assignment 1      (out of 12)
ass2    = mark for assignment 2      (out of 16)
exam    = mark for final exam        (out of 60)
okExam  = exam >= 24/60  (40%)       (after scaling)

mark    = ass1 + ass2 + quizzes + exam

grade   = HD|DN|CR|PS  if mark >= 50 && okExam
        = FL           if mark <  50 && okExam
        = UF           if !okExam

COMP3311 23T3 ♢ Overview ♢ [17/27]
❖ Textbook (options)

Earlier editions of texts are ok
COMP3311 23T3 ♢ Overview ♢ [18/27]
❖ Database Management Systems

Two example DBMSs for prac work:

Comments on using a specific DBMS:
** Unless it seriously violates SQL standards ... I mean you, MySQL
COMP3311 23T3 ♢ Overview ♢ [19/27]
❖ Further Reading Material

The on-line documentation and manuals provided with:

Some comments on technology books: Aside: once you understand the concepts, the documentation is sufficient
COMP3311 23T3 ♢ Overview ♢ [20/27]
❖ Software

Software versions that we'll be running this semester (TBC):

If you install them at home: Alternative to installing at home: Details on setting up a PostgreSQL server are in the Prac Exercise 02
COMP3311 23T3 ♢ Overview ♢ [21/27]
❖ Software (cont)

How to access the vxdb2 server

On the vxdb2 server you have The actual hostname of the vxdb2 server is nw-syd-vxdb2

More details on how to set up PostgreSQL in Prac Exercise 02

COMP3311 23T3 ♢ Overview ♢ [22/27]
❖ Doing Database work on vxdb2


DO NOT run vscode on vxdb2

Run a Terminal window on a VLab server; edit files there

Run another Terminal window and ssh to nw-syd-vxdb2

Both Terminals can access the same directory, with your SQL code

Run vscode (if you must) on the VLab server

COMP3311 23T3 ♢ Overview ♢ [23/27]
❖ Overview of the Databases Field


[Diagram:Pics/intro/overview.png]

COMP3311 23T3 ♢ Overview ♢ [24/27]
❖ Database Application Development

A variation on standard software engineering process:

  1. analyse application requirements
  2. develop a data model to meet these requirements
  3. check data model for redundancy (using relational theory)
  4. implement the data model as relational schema
  5. define operations (transactions) on this model
  6. implement operations via SQL and procedural PLs
  7. construct a program interface to these operations
  8. monitor performance and "tune" the schema/operations
At some point, populate the database (may be via interface)

During the course, we consider these in the order 2, 4, 6, 7, 3

COMP3311 23T3 ♢ Overview ♢ [25/27]
❖ Database System Architecture

The typical environment for a modern DBMS is:

[Diagram:Pics/intro/dbms-arch.png]

SQL queries and results travel along the clientserver links

COMP3311 23T3 ♢ Overview ♢ [26/27]
❖ Database System Architecture (cont)


SQLite has a simpler (not client-server) arhcitecture:


[Diagram:Pics/intro/dbms-arch2.png]


Although it does have an API for use from programming languages.

COMP3311 23T3 ♢ Overview ♢ [27/27]


Produced: 10 Sep 2023