Professional Documents
Culture Documents
AND DEVELOPMENT
SQL(Creating data structures)
STUDENT NAME
Student Id
Theory Questions
Solution 1. SQL Data Definition Language (DDL) refers as SQL command used for creating,
Modifying and deleting a database table. These commands work on the table structure only.
Practical Questions
Solution 2. Created all the tables successfully. The tables created are Customer, Part, Order, and
OrderLine.
Solution 3. Yes, we have to create the tables in the particular order. This is because the order
table cannot be created before customer table and OrderLine table cannot be created before Order,
and Part table as the references of previous tables are added in the next table. If we try to create
Order and OrderLine table first, then this gives an error for not found the reference as the tables
do not exist. The Customer and Part tables can be created in any order.
Solution 4. The following data types are available in the Ms. Access database:
These are the basic data types commonly used in Ms. Access
Solution 5. Yes, from my view there is a need to add more constraints. The updated queries are
the following:
PostCode INTEGER,
DateOfBirth DATETIME );
Order table
Solution 6.
Solution 7.
Alter table Customer add Column ContactPhone LONG, Comments LongText, CreditLimit
Currency not null;