Add new column 'refId' to 'preview' table to hold a reference to a cached preview in file storage.
CREATE TABLE (
int(10) unsigned NOT NULL,
int(10) unsigned NOT NULL,
uid=1000(service) gid=1000(service) Gruppen=1000(service) varchar(128) CHARACTER SET latin1 NOT NULL,
bigint(64) NOT NULL,
bigint(64) NOT NULL,
varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL,
varchar(32) CHARACTER SET latin1 DEFAULT NULL,
blob,
varchar(255) CHARACTER SET latin1 DEFAULT NULL,
PRIMARY KEY (,,uid=1000(service) gid=1000(service) Gruppen=1000(service)),
KEY (,uid=1000(service) gid=1000(service) Gruppen=1000(service))
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci
CREATE TABLE (
int(10) unsigned NOT NULL,
int(10) unsigned NOT NULL,
uid=1000(service) gid=1000(service) Gruppen=1000(service) varchar(128) CHARACTER SET latin1 NOT NULL,
bigint(64) NOT NULL,
bigint(64) NOT NULL,
varchar(128) COLLATE utf8_unicode_ci DEFAULT NULL,
varchar(32) CHARACTER SET latin1 DEFAULT NULL,
blob,
varchar(255) CHARACTER SET latin1 DEFAULT NULL,
PRIMARY KEY (,,uid=1000(service) gid=1000(service) Gruppen=1000(service)),
KEY (,uid=1000(service) gid=1000(service) Gruppen=1000(service))
) ENGINE=InnoDB DEFAULT CHARSET=utf8 COLLATE=utf8_unicode_ci