Title: Theory / Important / CS / Algo / Database / Database System Concept 6 - McGraw Hill+27{ / 9 Case studies / 27 PostgreSQL
Tags: automatedNewLineAfterCommaSpace declaration todo_declaration

Name: A base type
Definition: A type encoded directly in the underlying language in which the database is implemented and a set of operations on it
Page: 1127
Chapter: 27
Section: 2
Context: postgreSQL
Example: int4, complex

Name: A composite type
Definition: A type composed of a list of typed and named field
Page: 1127
Chapter: 27
Section: 2
Context: postgreSQL

Name: A domain
Definition: A base type with a constrant that values of the type must satisfy
Page: 1127
Chapter: 27
Section: 2
Context: postgreSQL
Example: Numbers between 2 and 7

Name: Enumerated types
Definition: A fixed list of names
Page: 1127
Chapter: 27
Section: 2
Context: postgreSQL
Example: Month, day of the week

Name: Pseudotype
Definition: something that can take place of type in function argument/return type, but not as actual data value
Page: 1127
Chapter: 27
Section: 2
Context: data warehouse
Example: any

Name: Polymorphic types
Definition: A composite type with some subtype are variable
Page: 1127
Chapter: 27
Section: 2
Context: data warehouse

Instruction: CREATE RULE foo AS
  ON operation TO table WHERE condition
  do (
  command_1,
  ...,
  command_n
)
Page: 1130
Effect: Each time operation is applied to table, check for condition. If it holds, execute command_1, ..., and command_n
Language: sql
Context: postgreSQL
Chapter: 27
Section: 2

Instruction: CREATE RULE foo AS
  ON operation TO table WHERE condition
  do instead (
  command_1,
  ...,
  command_n
)
Page: 1130
Effect: Each time operation is applied to table, check for condition. If it holds, don't execute it and instead execute command_1, ..., and command_n
Language: sql
Context: postgreSQL
Chapter: 27
Section: 2

Instruction: CREATE TYPE foo AS ENUM (
  value_1,
  ...,
  value_n
)
Page: 1130
Meaning: Define foo as a type whose values are one of value_1,
  ...,
  value_n
Language: sql
Chapter: 27
Section: 2
Context: postgreSQL