ISYS2120 Cheatsheet · Data and Information Management

University of Sydney · Cheatsheet for the final exam. Semester 2 formal examination period, from 16 November 2026 (the Exams Office publishes the exact date). Full ISYS2120 study guide →

A4 landscape · 7pt · 6 columns · closed-book recall2 sides · ISYS2120 · USyd
ISYS2120
Data and Information Management
The University of Sydney · Level 2 · Semester 2 2026
ISYS2120 cheatsheet QR code – open the full ISYS2120 study guide
Full guide + ask Sia about ISYS2120
SIDE 1/2   DEFINITIONS → DECISIONS → QUERY LOGIC → CONSTRAINTS → ALGEBRAClosed-book memory sheetWhat must be in your head

0 · Exam Mapcourse + brief

Final 50Quizzes 21SQL 6E 3CM 10OQ 10
Final Exam50%weekly quizzes21%
SQL tasks6%Early feedback quiz3%
Conceptual Model Assignment10%SQL Online Quiz10%

official rulePaper-based exam, 2 hours, closed book. ISYS2120 current Canvas Assessment overview; 2026 intro slides

Retrieval order: define the object → state the formal rule → apply it to the shown rows → name the retained/rejected result → test one boundary case. A plausible diagram or query is incomplete until its meaning and result are checkable.

1 · Database Corefoundations

TermRecite
Datarecordable facts that matter and must persist
Databasepersistent organisational data
DBMSsoftware coordinating storage, metadata, queries, integrity, sharing, recovery and security
Metadatastructure, origin and obligations describing data
Cataloguedatabase-held names, datatypes and constraints

A relation has uniformly structured tuples over named attributes and domains. Schema is the stable description; instance is the current contents. Every update changes the instance; every valid instance must fit the schema. Mathematical relations have no duplicate rows and no meaningful row order.

EXTERNALviewsCONCEPTUALschemaPHYSICALstoragelogicalphysicalindependence protects level above
External → Conceptual → Physical; insulation.

Recall → Logical independence protects user views; physical independence protects the conceptual design from storage changes.

2 · Keys & Integrityfoundations

candidate-key testProposed columns distinguish every row in every permitted state, not merely the sample; one counterexample rejects the claim.

Domain/typepermitted value kind
PRIMARY KEYselected identity: unique and present
FOREIGN KEYnon-NULL value matches a target key

4 · ER Constraint DecoderER modelling

Start from requirements. An entity type groups distinguishable objects; an attribute describes an entity or relationship; a relationship type records a fact among roles. Ask whether each noun needs independent identity and retained facts.

Composite attributehas meaningful parts
Multivalued attributeone entity may have several values
Relationship attributedepends on the participant combination
ENTITY ARELATION-SHIPENTITY Bmin? max?min? max?read A→B, then B→A
Read maximum and minimum at both ends.
QuestionConstraintMeaning
How many at most?maximum cardinality / key constraintlimits counterparts
Must every one participate?minimum / total participationat least one relationship instance
Who does what?role namedisambiguates recursive participation

Say every mark in plain domain language. Then narrate one valid and one invalid population. If requirements are silent, state the assumption instead of smuggling in a business rule.

Weak entity

A weak entity's identity combines an owner's key with a local discriminator. Few attributes or low importance do not make it weak; owner-dependent identity does.

A key is minimal: remove a necessary component and it no longer distinguishes every entity.

OWNERkeyIDENTIFYINGlinkWEAKentityidentity = owner key + discriminator
Owner key + discriminator identifies the weak entity.

Harder structures

Recursivesame entity type plays distinct named roles
ISAchoose subtype constraints deliberately; preserve inheritance
Ternary / aggregationkeep the combined fact when binary links would lose or invent combinations

5 · SQL: Build the Resultquery foundations

FROMJOIN /ONWHEREGROUPHAVINGSELECTORDERrows → groups → output → presentationplan meaning before clause syntax
Plan rows → groups → output; sort last.
Clause / ideaJobDiagnostic
SELECTtarget columns / expressionsonly requested output?
FROMsource relationsall needed, no extras?
JOIN / ONconnect matching factsmissing predicate multiplies rows
WHEREkeep rows whose predicate is TRUEboundary and NULL case?
GROUP BYpartition surviving rowsright population?
HAVINGfilter completed groupsaggregate belongs here
ORDER BYsort resultmembership unchanged

fast query planOUTPUT columns → SOURCE relations → CONNECTIONS → FILTERS → predicted smallest result.

NULL is unknown

Comparisons with NULL do not become TRUE; use IS NULL, not = NULL. Keep missing values explicit when predicting filters and aggregates. SQL normally preserves duplicate result rows; DISTINCT removes duplicates only when uniqueness is required.

Trap → DISTINCT is not a repair for a faulty join. First explain why repeated rows exist; then decide whether the requested projected values should be unique.

5b · SQL Contrast Deckquery foundations

PairDifference to recite
projection / selectionoutput attributes versus retained rows
equi-join / natural joinexplicit equality keeps both match columns; natural matches every same-named column and keeps one copy
alias / stored nametemporary scope name versus schema object name
duplicate rows / repeated factssame projection need not mean the source fact is duplicated
membership / orderWHERE decides inclusion; ORDER BY changes presentation
expression / stored valuetarget expression computes output without adding a base column

6 · Joins, Groups, TestsSQL + advanced

If the request says…Use / protect
only matching factsinner / theta join with explicit condition
every left row, even noneLEFT JOIN; unmatched right attributes become NULL
one table in two rolesaliases; qualify attributes
summary per valueGROUP BY that value
filter raw rowsWHERE before grouping
filter summariesHAVING after grouping
KEEP EMPTY?LEFT JOIN loansON key AND openWHERE r.openrejects NULL rowsYES: filter in ONNO: rows vanish
Put right filters in ON to retain empty left rows.

counting retained left rowsStart from every left entity → LEFT JOIN matches → GROUP BY left key → COUNT(non-NULL right key). COUNT(*) counts the joined row, including an unmatched NULL-extended row.

Diagnostic data

ordinary matchbase meaning
unmatched rowinner vs outer join
repeated projected valuebag vs DISTINCT
NULLthree-valued filter / aggregate
boundary value> versus ≥
empty groupretention and count choice

Predict intermediate rows by hand. The first stage where prediction and result diverge identifies the faulty clause. An accidental Cartesian product pairs every row from one source with every row from the other and can make credible-looking but inflated summaries.

Explain → State why every returned row satisfies the request and why one boundary row is excluded. A query that runs is not yet evidence that the meaning is right.

6b · Grouping Logicadvanced SQL

logical populationFROM/JOIN creates candidates → WHERE removes rows → GROUP BY partitions survivors → aggregates summarise each group → HAVING removes groups → SELECT forms output.

COUNT(*)counts retained joined rows
COUNT(column)ignores NULL in that column
Unmatched left rowone NULL-extended row survives a LEFT JOIN
Empty-match countcount a right-side key to obtain zero

7 · DDL as Contractschema design

ROW /UPDATEALL ACTIVERULESACCEPT /REJECTvalidate the complete post-change state
Each change is tested against every active rule.
DDL devicePromiseFailing probe
Datatypecolumn value kindincompatible value
NOT NULLvalue presentmissing mandatory field
PRIMARY KEYunique, non-NULL identityduplicate full key
UNIQUEdistinct non-NULL value/combinationrepeated candidate value
FOREIGN KEYmatching referenced keydangling non-NULL reference
CHECKrow satisfies Boolean ruleboundary-breaking value

SQL permits multiple NULLs in a UNIQUE column unless it is also NOT NULL. A composite primary key constrains the combination; individual components may repeat. Referential actions are domain policies: restriction blocks a change; cascading propagates it; setting NULL needs an optional reference. Historical retention may rule out automatic deletion.

answer scaffoldRequirement → declared type/constraint → attempted invalid row → named rejection → resulting stored table.

8 · ER → Relationsschema mapping

Conceptual patternRelational decision
strong entityrelation; entity key becomes relation key
simple attributecolumn
composite attributeflatten into component columns
multivalued attributeseparate relation
1:M relationshipone-side key migrates as FK to many side
M:N relationshipassociative relation with both FKs; relationship attributes live there
weak entityowner key + discriminator form identity
total participationuse NOT NULL where the mapping can enforce it
ENTITY AASSOCIATIVEA_key · B_keyrel. attributesENTITY BM:N fact becomes its own relation
M:N becomes a relation holding both keys.

9 · Relational Algebraalgebra + SQL

OperatorEffectCheck
σp(R)selection: rows satisfying pheading preserved
πA(R)projection: named attributesduplicates removed under set semantics
ρ(R)rename relation/attributesscope unambiguous; enables self-join
R × Sall tuple combinationsusually constrain into join
R ⋈p Spairs satisfying pmeaningful match
∪, ∩, −set union/intersection/differenceunion-compatible headings/domains
R ÷ Scandidates paired with every S tuplecomplete divisor audited

translation warningSQL SELECT ≈ algebraic projection π; SQL WHERE ≈ algebraic selection σ.

INPUTrelationALGEBRAoperatorRESULTrelationlabel every intermediate heading + tuples
Every operator returns another relation.

Push selection before expensive combinations when equivalent. For set operators, matching column counts are insufficient: corresponding attributes need compatible domains and meanings. Equivalence means the same relation for every valid database state under the stated set/bag and NULL semantics, not agreement on one convenient dataset.

10 · “Every” / Divisionadvanced SQL

KEEP CANDIDATE c IFFNO required r lacks a matching fact(c,r)division ⇔ double NOT EXISTS
“Every” means no required item is missing.

double negationSELECT DISTINCT c.id FROM Candidate c
WHERE NOT EXISTS (
 SELECT 1 FROM Required r
 WHERE NOT EXISTS (
  SELECT 1 FROM Fact f
  WHERE f.id=c.id AND f.item=r.item));

  1. Write the complete divisor / required list.
  2. For each candidate, tick every required pairing.
  3. One missing pair removes the candidate.
  4. Extra pairings do not disqualify it.
  5. Preserve both correlations; dropping one can reverse the meaning or test a global condition.
https://www.asksia.ai/cheatsheet/usyd-isys2120 · Full ISYS2120 study guide →
Forward this to your tutorial group · Shared by ________
AskSiav2 · 2026-10-25 · side 1/2
Your exam is closed book: nothing printed goes in. Use this sheet to revise and self-test, not to carry.
Semester 2 formal examination period, from 16 November 2026 (the Exams Office publishes the exact date).
ISYS2120
Worked Recall · Judgement Cards · Exam-Morning Plan
Data and Information Management · closed-book self-test side
ISYS2120 cheatsheet QR code – open the full ISYS2120 study guide
Full guide + ask Sia about ISYS2120
SIDE 2/2   5 WORKED PATHS · IF X → Y CARDS · CLASSIC TRAPS · MORNING RETRIEVALAnswer before revealing the pathUse paper; no software

11 · Worked: Linked Factsfoundations · source values

Given. Supplier: (S1, North Tools), (S2, Metro Hire). Product: (P10, Drill, S1), (P11, Saw, S2), (P12, Sander, S1). Return products supplied by North Tools.

SUPPLIERS1 · North ToolsS2 · Metro HirePRODUCTP10 · Drill · S1P11 · Saw · S2P12 · Sander · S1
Follow S1 → keep P10 Drill and P12 Sander.
  1. Find North Tools in Supplier → linking value S1.
  2. Keep Product rows whose supplier_id matches S1.
  3. Project requested product columns; preserve both matches.
  4. Result: P10 | Drill; P12 | Sander. P11 is excluded because S2 identifies Metro Hire.

Trap → Do not match on supplier name when the schema links through supplier_id.

12 · Worked: Filter TripsSQL foundations · source values

Trip(trip_id, depart_date, capacity, booked): T1=(2026-09-09,4,4), T2=(2026-09-10,6,4), T3=(2026-09-11,3,3), T4=(2026-09-12,8,5). Return trips on/after 2026-09-10 with spare seats.

SELECT trip_id, capacity - booked AS spare_seats
FROM Trip
WHERE depart_date >= '2026-09-10'
 AND capacity > booked
ORDER BY trip_id;

RowDate?Spare?Output
T1no—exclude
T2yes6−42
T3yes3>3 falseexclude
T4yes8−53

Answer: T2 | 2; T4 | 3. Decide membership before computing the target expression.

12b · Re-run Without Lookinglinked rows + SELECT

PromptAnswer path
Why do P10 and P12 both remain?both Product tuples carry S1; sharing a supplier does not merge distinct products
Why exclude P11?its linking value S2 identifies Metro Hire
What if you project only supplier_id?repeated S1 values remain in SQL unless DISTINCT is requested
Which Trip predicate removes T1?date threshold
Which removes T3?capacity > booked is false at equality

13 · Worked: Weak SessionER modelling · source values

A FitnessClass is identified by class_code. Session numbering restarts inside each class; a Session cannot exist without its class and has start_time. For YOGA: session 1 at 09:00; session 2 at 17:00.

FITNESSCLASSclass_code PKSESSIONclass_code + noSession(code PK/FK, no PK, start)YOGA · 1 · 09:00YOGA · 2 · 17:00
Owner key + discriminator identifies Session.
  1. Owner: FitnessClass with class_code key.
  2. Local discriminator: session_no; not globally unique.
  3. Map Session(class_code, session_no, start_time); composite PK is (class_code, session_no), and class_code is also the owner FK.
  4. Another class may validly have session_no 1.

Trap → session_no alone would wrongly prevent PILATES | 1; omitting class_code loses the identifying owner.

14 · Worked: Composite DDLschema design · source values

WorkshopSession(event_code, sequence_no, room, capacity): the first two columns identify a row; capacity must be positive.

CREATE TABLE WorkshopSession(
 event_code TEXT NOT NULL,
 sequence_no INTEGER NOT NULL,
 room TEXT,
 capacity INTEGER CHECK(capacity > 0),
 PRIMARY KEY(event_code, sequence_no));

AttemptResult
E1,1,R2,20store
E1,2,R3,15store
E2,1,R2,10store
E1,1,R9,30reject duplicate pair

Repeated E1 and repeated sequence_no 1 are individually valid. The full pair (E1,1) cannot repeat; the failed row is not stored.

14b · Constraint Attack DeckDDL self-test

AttackExpected explanation
omit event_codeNOT NULL / primary-key identity cannot be missing
repeat E1 with sequence 3valid: the full pair is new
use E3 with sequence 1valid under the shown table: sequence_no is not globally unique
capacity at or below zeroCHECK(capacity > 0) rejects the row

15 · Worked: Divisionadvanced SQL · source values

ToolStock: (D1,Hammer), (D1,Drill), (D2,Hammer), (D3,Hammer), (D3,Drill), (D3,Saw). Required: Hammer, Drill. Which depots stock every required tool?

depotHammerDrillextraD1✓✓—D2✓✗—D3✓✓Sawquotient = {D1, D3}
D1,D3 pass; D2 lacks Drill; extra Saw is fine.
  1. Divisor contains Hammer and Drill.
  2. D1 has both; retain. D2 lacks Drill; remove. D3 has both; retain.
  3. ToolStock ÷ Required = {D1, D3}.
  4. Equivalent SQL uses correlated double NOT EXISTS; compare its ordered output with the hand quotient.

SELECT DISTINCT t.depot_id FROM ToolStock t
WHERE NOT EXISTS (SELECT 1 FROM Required r
 WHERE NOT EXISTS (SELECT 1 FROM ToolStock x
 WHERE x.depot_id=t.depot_id AND x.tool=r.tool))
ORDER BY t.depot_id;

16 · Five Answer Pathsfast recall

Linked factslookup key → match FK → project
SELECTsources → filters → expression → order
Weak entityowner → discriminator → composite identity
DDLrequirement → constraint → violating row → stored state
Divisiondivisor list → candidate ticks → quotient

Closed-book drill → Cover the worked path; reproduce the result and one rejected row. Then explain the formal rule without looking.

16b · Algebra Micro-Drillsoperator trace

PromptWhat to write first
keep open loansσstatus='open'(Loan); same heading, fewer tuples
return memberId onlyπmemberId(…); name output heading and remove duplicate tuples under set semantics
compare two bookingsρ creates two scopes before the self-join
combine then matchproduct creates all pairs; theta-join adds the meaningful predicate

17 · If You See X → Do Ymethod chooser

SEEDOevery / all required÷ / 2×NOT EXISTSinclude zero rowsLEFT JOIN; count keynumber per ownerweak = owner + no.
Trigger word → method; verify domain meaning.
SeeDo
“how many at most?”maximum cardinality in both directions
“must participate?”minimum / total participation
same entity twicerole names + aliases / rename
raw row conditionWHERE
aggregate conditionHAVING
unique output valuesDISTINCT, after join is proven
missing valueIS NULL; predict UNKNOWN comparisons
many-to-manyassociative relation with both keys
invalid history deletionrestrict; do not assume CASCADE
set union/differencecheck headings, domains and meanings

universal sentence“There does not exist a required item for which there does not exist a matching fact.”

18 · Result-Prediction Gridquery verification

Add this rowIt exposesWrong symptom
unmatched parentouter joinrow disappears
duplicate projected valuebag semanticsunexpected repetition
NULL optional valueunknown / aggregatesrow silently filtered
boundary equality> vs ≥edge membership wrong
one missing required pairdivisionfalse universal pass
duplicate composite pairkey scopeinvalid row accepted

Best evidence → The smallest counterexample that separates your intended result from a plausible wrong result.

18b · Modelling Judgement CardsER self-test

QuestionDecision test
Entity or attribute?Does it need independent identity, retained facts and participation in relationships?

19 · Classic Trap Boardall five chapters

PROPOSEanswerATTACKboundaryCORRECTruleconstruction ↔ refutation
Propose → attack a boundary → correct the rule.
Wrong moveCorrection to recite
sample rows prove a keykey must distinguish every permitted state
cardinality = participationmaximum and minimum are separate
few attributes ⇒ weakweak means owner-dependent identity
= NULLuse IS NULL; NULL comparison is unknown
two tables, no join predicateCartesian product; connect matching values
DISTINCT hides extra rowsrepair join first; deduplicate only by meaning
aggregate in WHEREWHERE rows; HAVING groups
LEFT JOIN then right filter in WHEREput qualifying right filter in ON if unmatched left rows survive
COUNT(*) for optional matchescount a non-NULL right key
separate UNIQUE columns for pairone composite constraint on the pair
M:N foreign key on one sideassociative relation
SQL SELECT = algebraic selectionSQL SELECT maps to projection π
one match proves “every”audit all divisor items; seek missing pair
same output on one dataset proves equivalencemust agree on every valid state under stated semantics

Correction language → “This fails when …; the rule is …; therefore the result must …”. That sentence forces a counterexample, a formal principle and an observable consequence.

19b · Definition Flash Gridfast recall

TermDistinguishing sentence
schema / instancestable structure versus contents at one time
relation / table outputset of tuples with named attributes; mathematical relation has no order or duplicates
candidate / primary keyany row-distinguishing combination versus the selected declared identifier
foreign keynon-NULL reference must match a target key
total participationevery entity must occur in at least one relationship instance
selection / projectionretain rows versus retain attributes
WHERE / HAVINGfilter candidate rows versus completed groups

20 · Exam-Morning Planclosed-book retrieval

CLOSED BOOKretrieve aloudDEFINEDRAWTRACEATTACK
Define → draw → trace → attack, without looking.

Last revision session

  1. From memory, contrast data/database/DBMS; schema/instance; candidate/primary/foreign key; SQL/algebraic selection/projection.
  2. Draw External → Conceptual → Physical and name logical versus physical independence.
  3. Draw one ER relationship; read maximum and minimum both ways. Add a weak entity and explain its composite identity.
  4. Write one SELECT with a join, WHERE, GROUP BY and HAVING. Predict the intermediate rows.
  5. Write one CREATE TABLE with a composite key, FK and CHECK; invent a failing row for each.
  6. Compute the ToolStock division and narrate double NOT EXISTS.

On the paper

Definitionsterm → distinguishing contrast → consequence
ERrequirements → identity → max/min both ways → counterexample
SQLoutput → sources → joins → filters → result rows
DDLrule → syntax → invalid state rejected
Algebraheading + tuples after every operator
Universalcomplete required list; find missing pair

Never stop at a name. A full answer says what the object is, what rule applies, what happens to the supplied rows, and which counterexample would falsify the proposed answer.

21 · 60-Second Oral Checkfast recall

Why a DBMS?shared persistent data + catalogue + integrity + controlled services
What proves a key?uniqueness over all permitted states
Why weak?identity depends on owner + discriminator
WHERE vs HAVING?rows before grouping vs completed groups
Why LEFT JOIN?retain unmatched left rows with NULL right side
Why division?candidate related to every required tuple

Finish → If formal and domain explanations disagree, revisit the assumption before practising another problem.

https://www.asksia.ai/cheatsheet/usyd-isys2120 · Full ISYS2120 study guide →
Forward this to your tutorial group · Shared by ________
AskSiav2 · 2026-10-25 · side 2/2
Your exam is closed book: nothing printed goes in. Use this sheet to revise and self-test, not to carry.
Semester 2 formal examination period, from 16 November 2026 (the Exams Office publishes the exact date).

Want one for YOUR exact syllabus?

Sia is your free desktop study agent. Drop your University of Sydney ISYS2120 slides — Sia builds a sheet tailored to YOUR exam. Better than this library because it knows YOUR materials.

↓ Download Sia · Free