Skip to content

NATIONAL

CREATE TABLE Employee (
EmployeeID INT PRIMARY KEY,
EmployeeName CHAR(30),
EmployeeNationality NATIONAL CHAR(50)
);
Query OK, 0 rows affected (0.23 sec)

In the example code, NATIONAL CHAR(50) is specified as a column type for EmployeeNationality in the Employee table. NATIONAL CHAR is a data type in SQL that is used to store character string type data, where the character count can be up to the number specified in parenthesis. Specifically, NATIONAL CHAR is a fixed-length character string. Between CHAR and NATIONAL CHAR, their key difference is the usage of the NATIONAL keyword, which ensures that the column will store characters of the national character set.