Simple web-page that shows articles written by users.
Bootstrap and JQuery come from their respective official CDNs.
create table Users
(
Email varchar(255) not null,
Username varchar(32) not null,
Password binary(60) not null,
UserURL varchar(10) not null
primary key,
CreatedOn timestamp default CURRENT_TIMESTAMP not null
)
;
create index Users_UserURL_index
on Users (UserURL)
;
create table Posts
(
Title varchar(255) not null,
Content text not null,
PostURL varchar(10) not null
primary key,
CreatorURL varchar(10) not null,
CreatedOn timestamp default CURRENT_TIMESTAMP not null,
constraint Posts_Users_UserURL_fk
foreign key (CreatorURL) references Users (UserURL)
on update cascade on delete cascade
)
;
create index Posts_PostURL_index
on Posts (PostURL)
;
create index Posts_Users_UserURL_fk
on Posts (CreatorURL)
;