create table follows
(
    id        varchar(36)                           not null comment 'identifier of a follow'
        primary key,
    source_id varchar(36)                           not null comment 'identifier of the follower user',
    target_id varchar(36)                           not null comment 'identifier of the followed user',
    iat       timestamp default current_timestamp() not null comment 'timestamp of the follow action'
)
    comment 'follows of users';

create table users
(
    id               varchar(36)                           not null comment 'unique identifier of a user'
        primary key,
    username         varchar(14)                           not null comment 'username of a user',
    display_name     varchar(16)                           not null comment 'displayName of a user',
    email            varchar(32)                           not null comment 'email of a user',
    iat              timestamp default current_timestamp() not null comment 'timestamp of when the account was created',
    uat              timestamp default current_timestamp() not null comment 'timestamp of the last update of the account information',
    deactivated      bit       default b'0'                not null comment 'does te account is deactivated',
    hash             varchar(97)                           not null comment 'hash of the password',
    email_activation int(6)                                null comment 'email activation code',
    admin            bit       default b'0'                not null comment 'state for administration permission',
    avatar_id        varchar(16)                           null comment 'stored avatar identifier of a user',
    gdpr             timestamp default current_timestamp() null,
    constraint users_email_pk
        unique (email),
    constraint users_username_pk
        unique (username)
)
    comment 'Table of the users' collate = utf8mb4_unicode_ci;


