Created
February 27, 2019 17:07
-
-
Save tomredsky/282540e6845024e83a58ac6c125c3cf3 to your computer and use it in GitHub Desktop.
media_files table
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
/* Not creating a fk between spl_number and ct.num | |
as we may use pg_logical to replicate this table | |
to the PG DB on www. If we don't it will be trivial | |
to add one later. | |
Also not adding a unique key between md5 as there are | |
about 2,100 duplicates at the moment. | |
*/ | |
create table media_files( | |
spl_number varchar(9) not null, | |
pathpart varchar(64) not null, | |
md5 varchar(32) not null, | |
dimensions varchar(11) not null, | |
mtime int not null, | |
unique(spl_number, pathpart) | |
); |
Sign up for free
to join this conversation on GitHub.
Already have an account?
Sign in to comment