From 2e4c815a102b0aaf16d1f2753f3fe36b5f999f72 Mon Sep 17 00:00:00 2001 From: Joachim Lusiardi Date: Tue, 15 Nov 2016 21:31:37 +0100 Subject: [PATCH] Add of db update script --- database_upgrades/upgrade_freckles_to_gillian.sql | 11 +++++++++++ 1 file changed, 11 insertions(+) create mode 100644 database_upgrades/upgrade_freckles_to_gillian.sql diff --git a/database_upgrades/upgrade_freckles_to_gillian.sql b/database_upgrades/upgrade_freckles_to_gillian.sql new file mode 100644 index 0000000..6291b52 --- /dev/null +++ b/database_upgrades/upgrade_freckles_to_gillian.sql @@ -0,0 +1,11 @@ +CREATE TABLE IF NOT EXISTS `service` ( + `id` int(11) NOT NULL AUTO_INCREMENT, + `date` date DEFAULT NULL, + `odometer` int(11) DEFAULT NULL, + `vehicle_id` int(11) DEFAULT NULL, + `costs` decimal(10,2) DEFAULT NULL, + `description` varchar(4096) DEFAULT NULL, + PRIMARY KEY (`id`), + KEY `vehicle_id` (`vehicle_id`), + CONSTRAINT `service_ibfk_1` FOREIGN KEY (`vehicle_id`) REFERENCES `vehicle` (`id`) +) ENGINE=InnoDB AUTO_INCREMENT=16 DEFAULT CHARSET=latin1; \ No newline at end of file