B ITM 330 Lecture Notes - Lecture 4: Unique Key, Sql, Data Definition Language
Document Summary
Sql for data definition: the sql data definition statements include: Alter: to modify the structure and/or characteristics of database objects. Truncate: to delete table data while keeping structure, creating database tables. Sql for data definition create: the sql create table statement: Sql for data definition create with constraint i: creating database tables with primary key constraints, the sql create table statement, the sql constraint keyword. Sql for data definition create with constraint ii: creating database tables with composite primary keys using primary key constraints, the sql create table statement, the sql constraint keyword. Null: adding primary key constraints to an existing table. Primary key constraint alter i: the sql alter statement. Composite primary key constraints alter ii: adding a composite primary key constraint to an existing table, the sql alter statement. Primary key(empid, skillid): to add a row to an existing table, use the insert statement, non-numeric data must be enclosed in straight ( " ) single quotes.