COGS 121 HCI Programming Studio
Week 03 - Tech Lecture
COGS 121 HCI Programming Studio Week 03 - Tech Lecture - - PowerPoint PPT Presentation
COGS 121 HCI Programming Studio Week 03 - Tech Lecture Housekeeping Assignment #1 extended to Monday night 11:59pm Assignment #2 to be released on Tuesday during lecture Database Management Systems and SQL Week 03 - Tech Lecture
Week 03 - Tech Lecture
11:59pm
during lecture
Week 03 - Tech Lecture
https://pgexercises.com
activities of organizations.
software package designed to store and manage databases.
access different data subsets.
describing data.
the a given data model.
today.
columns.
fields.
name of the relation, and name and type of each field:
age: integer, gpa:real)
v.g.: {<53666,Jones,jones@cs,18,3.4>, <53688,Smith,smith@ee,18,3.2>, <53650,Smith,jones@math,19,3.8>, ...}
—> describes data in terms of the data model of the DBMS
in a simple way.
SQL(Structured Query Language).
success of relational databases
and DML)
model terms relation, tuple, and attribute
each element
constructs
PRECISION
CHARACTER VARYING(n)
DD
seconds
decrement an absolute value of a date, time, or timestamp
primary key of a relation
DEFAULT
is the same for both ON DELETE and ON UPDATE
Employee Name Dept Department Dept Manager SQL
SELECT Manager FROM Employee, Department WHERE Employee.name = "Clark Kent” AND Employee.Dept = Department.Dept
by the query.
to be retrieved by the query.
retrieved tuple
tuples
explicitly
ASC, E.Fname ASC
(/)
single-tuple summary
HAVING clause
grouping attribute
the tuple
deleted
tuples
—> http://www.postgresql.org/ftp/pgadmin3/release/v1.22.0/
cogs121_16_raw
password ‘mcH8Yjs_n#2(xp’, schema: cogs121_16_raw
password ‘sql4cogs121’ schema: cd