CREATE TABLE IF NOT EXISTS `#__eventgallery_downloadlog` (
    `id` int(11) unsigned NOT NULL AUTO_INCREMENT,
    `folder` varchar(255) NOT NULL,
    `file` varchar(255) NOT NULL,
    `type` varchar(128) NOT NULL DEFAULT '',
    `reference` text,
    `userid` varchar(45),
    `created` timestamp NULL DEFAULT NULL,
    PRIMARY KEY (`id`),
    KEY `file` (`folder`,`file`),
    KEY `index_file` (`file`),
    KEY `index_folder` (`folder`),
    KEY `index_userid` (`userid`)
    ) ENGINE=InnoDB ROW_FORMAT=DYNAMIC DEFAULT CHARSET=utf8 AUTO_INCREMENT=1;
