From 846fc51f612997efbee1e5a0d05b773b5a4c7f73 Mon Sep 17 00:00:00 2001 From: Bharat Mediratta Date: Sun, 5 Apr 2009 03:54:08 +0000 Subject: Optimization: add all exif/iptc keys in a single insert, instead of many separate queries. In the process, rip out the summary column, we weren't using it. Clean up the test, and drop the exif_records database on uninstall. --- modules/exif/helpers/exif_installer.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) (limited to 'modules/exif/helpers/exif_installer.php') diff --git a/modules/exif/helpers/exif_installer.php b/modules/exif/helpers/exif_installer.php index 80990917..b0173e41 100644 --- a/modules/exif/helpers/exif_installer.php +++ b/modules/exif/helpers/exif_installer.php @@ -27,10 +27,9 @@ class exif_installer { `id` int(9) NOT NULL auto_increment, `item_id` int(9) NOT NULL, `name` varchar(64) NOT NULL, - `summary` boolean NOT NULL, `value` varchar(1024) NOT NULL, PRIMARY KEY (`id`), - UNIQUE KEY(`item_id`, `summary`, `name`)) + UNIQUE KEY(`item_id`, `name`)) ENGINE=InnoDB DEFAULT CHARSET=utf8;"); $db->query("CREATE TABLE IF NOT EXISTS {exif_records} ( `id` int(9) NOT NULL auto_increment, @@ -45,6 +44,7 @@ class exif_installer { static function uninstall() { $db = Database::instance(); $db->query("DROP TABLE IF EXISTS {exif_keys};"); + $db->query("DROP TABLE IF EXISTS {exif_records};"); module::delete("exif"); } } -- cgit v1.2.3