ECE356 Lecture Notes - Lecture 6: Referential Integrity, Character Encoding, Mcgraw-Hill Education

56 views8 pages

Document Summary

We have thus far not yet learned about how to formally create relations. The sql data de nition language (ddl) looks a lot like the query language that we have used thus far, but it allows us to de ne the structure of the data. Speci cally, our data de nition language allows us to de ne [sks11]: the schema of each relation, the type of each attribute, integrity constraints, indices on relations, security/authorization information for a relation, physical storage structure. If we wish to de ne a sql relation, the syntax for this is to create a relation (table) is called (unsurprisingly), The syntax for this command requires a name as well as a listing of the attributes ( elds) and their types (de nitions). It is also customary to include at least one constraint, the primary key. As before we put a semicolon at the end of the statement to designate the end of the statement.

Get access

Grade+20% off
$8 USD/m$10 USD/m
Billed $96 USD annually
Grade+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
40 Verified Answers
Class+
$8 USD/m
Billed $96 USD annually
Class+
Homework Help
Study Guides
Textbook Solutions
Class Notes
Textbook Notes
Booster Class
30 Verified Answers

Related Documents