Example 17:
CREATE TABLE Employee (EmpId INTEGER NOT NULL,Name CHAR(40) NOT NULL);
DESCRIBING the structure of a table
Syntax:
DESCRIBE <table_name>;
Example 18:
DESC Employee;
RESULT:
+-------------+---------------------+------+-----+---------+
| Field | Type | Null | Key | Default |
+-------------+---------------------+------+-----+---------+
|EmpId | bigint(20) | | PRI | NULL |
| Name | varchar(100) | | | 0 |
|Age | varchar(200) | | | 0 |
+---------------+--------------------+------+------+----------+
3 rows in set (0.00 sec)
Go To
Index
|