SYS 2202 Lecture Notes - Lecture 4: Unique Key, Data Type, Foreign Key
Document Summary
Structure of data: includes field names and allowed values. Conceptual/physical data model: operations on the data: data retrieval/modification. Efficient way to implement operations: constraints on data: limits values in data model. Defines valid data when adding or uploading entry. Tables relations i: columns- attributes , rows- tuples and specified by values of attributes, operations are generally queries, which retrieve data, ordered n-tuple/cartesian product? c. 1: database: collection of relations, database schema: set of all relation schemas in database d. Keys of relations: constraint on a relation, a key is a set of attributes that must have a unique value in every tuple. Underlined in tuple: no two tuples have the same value in key attributes. A set of attributes is a key, all tuples must have unique key iii: artificial keys: university id number, multi-attribute keys: may need more than one attribute to uniquely identify a tuple e. Domains: data type for attribute is its domain.