(iv) Display the structure of table CUSTOMER
Answer:
Answer by student
DESCRIBE CUSTOMER;
Detailed answer by teachoo
-lock-
To display the structure of a table in SQL, we can use the DESCRIBE statement . The syntax of this statement is:
DESCRIBE table_name;
- In this case, we want to display the structure of the CUSTOMER table. So, we write:
DESCRIBE CUSTOMER;
- This statement will show the following information about the CUSTOMER table:
- Field: the name of each column in the table
- Type: the data type of each column in the table
- Null: whether each column can have null values or not
- Key: whether each column is a primary key, a foreign key, or a unique key
- Default: the default value of each column in the table
- Extra: any extra information about each column in the table
-endlock-