w3d2 Flashcards

1
Q

iso restrictions on identifiers

A

must start with a letter
no longer than 128 characters
cannot contain spaces

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
2
Q

every data type is

A

either pre defined, constructed or user defined

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
3
Q

the name of a predefined or preconstructed data type is

A

a reserved word specified by that part of ISO/IEC 9075 that specifies the data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
4
Q

the name of a user defined data type

A

is provided in it’s definition

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
5
Q

predefined data type

A

datatype specified by ISO/IEC 9075 AND is provided by the SQL implementation

  • predefined even when the user is allowed to provide certain parameters
  • is atomic(not composed of values of other data types)
How well did you know this?
1
Not at all
2
3
4
5
Perfectly
6
Q

Each table has

A

a name that is unique within the schema

a structure that is the same for each of its records

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
7
Q

each attribute needs as a minimum

A

a unique name within the record

a data type ( which could be the name of a domain )

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
8
Q

Integrity constraints

A

define valid states of sql data by constraining values in base tables

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
9
Q

constaint can cause DBMS to

A

reject any atempt to insert, delete, or update against the restraint

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
10
Q

domain

A

set of legal values, (a sophisticated data type

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
11
Q

when not otherwise specified

A

the domain is the set of all legal values, that are based on the data type of the attribute

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
12
Q

CHECK

A

further specifies the legal values of a domain

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
13
Q

domain constraint

A

constraint specified for a domain

- applied to all columns that are based on that domain and to all values that are cast to that domain

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
14
Q

CONDITION ONLY CHECKED UPON

A

an insert or update of the record within the constraint

- not checked when records referred to in the check of the domain are updated or deleted

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
15
Q

The domain name can and should be used

A

in place of a data type by one or more data definitions

How well did you know this?
1
Not at all
2
3
4
5
Perfectly
16
Q

Domains important for

A

help us recognize if we are dealing with the same type of attribute or not
- a list of domains provides us with an idea about what types of data we have in our database
By using good domain names it’s clearer to know what your talking about it what you’re talking about

17
Q

entity integrity

A

deal with the relation of records to eachother in a table

18
Q

primary key

A

one set of attributes that uniquely defines a record

19
Q

Referential integrity

A

links a set of attributes in this record to a record key in another table

20
Q

referential integrity CASCADE

A

will delete the constrained row if the referenced row in the foreign key is deleted
will update the foreign key value if the referenced value is updated

21
Q

referential integrity SET NULL

A

will set each of the attributes in the foreign key to NULL if the referenced value is changed or it is deleted(provided the foreign key’s value is not defined as not null)

22
Q

referential integrity SET DEFAULT

A

Will set each of the attributes in the foreign key to it’s default if the referenced value is changed or it’s record is deleted (provided the foreign key attributes were defined with defaults)

23
Q

referential integrity NO ACTION

A

will not allow the updating or deleting of the referenced value (default if other not specified)

24
Q

ASSERTion

A

named constraint that may relate to the content of individual rows of a table, to the entire contents of a table, or to a state required to exist among a number of tables

  • an integrity constraint that is not directly linked to a table
  • similar to a CHECK but involves multiple tables
  • differs from a DOMAIN in that it is not a data type
  • can be automatically checked every time an INPUT, UPDATE or DELETE might violate it