eolas/Databases/SQL/8_CREATE.md
2022-08-21 11:00:04 +01:00

522 B

categories tags
Databases
Programming Languages
SQL

SQL: CREATE

Create a table (CREATE)

CREATE TABLE employee (
    employee_id text PRIMARY KEY,
    first_name text,
    surname text,
    address_number integer,
    address_1 text,
    address_2 text,
    locality text,
    region text,
    postal_code text,
    phone_number text,
    days_per_week real
    );

We specify the new table name first, then it's fields and their corresponding data types. We also set a primary key