From 72be7a82a5499723aae2fd10b8d00548db8304d0 Mon Sep 17 00:00:00 2001 From: Vishwas Babu A J Date: Fri, 10 Apr 2015 17:13:05 -0700 Subject: [PATCH] adding foreign key relationship and bumping up sql patch --- .../sql/migrations/core_db/V256__staff_image_association.sql | 1 - .../sql/migrations/core_db/V257__staff_image_association.sql | 3 +++ 2 files changed, 3 insertions(+), 1 deletion(-) delete mode 100644 mifosng-provider/src/main/resources/sql/migrations/core_db/V256__staff_image_association.sql create mode 100644 mifosng-provider/src/main/resources/sql/migrations/core_db/V257__staff_image_association.sql diff --git a/mifosng-provider/src/main/resources/sql/migrations/core_db/V256__staff_image_association.sql b/mifosng-provider/src/main/resources/sql/migrations/core_db/V256__staff_image_association.sql deleted file mode 100644 index 8d1bcfe17..000000000 --- a/mifosng-provider/src/main/resources/sql/migrations/core_db/V256__staff_image_association.sql +++ /dev/null @@ -1 +0,0 @@ -ALTER TABLE `m_staff` ADD COLUMN `image_id` BIGINT(20) NULL; \ No newline at end of file diff --git a/mifosng-provider/src/main/resources/sql/migrations/core_db/V257__staff_image_association.sql b/mifosng-provider/src/main/resources/sql/migrations/core_db/V257__staff_image_association.sql new file mode 100644 index 000000000..3a7af2f2f --- /dev/null +++ b/mifosng-provider/src/main/resources/sql/migrations/core_db/V257__staff_image_association.sql @@ -0,0 +1,3 @@ +ALTER TABLE `m_staff` + ADD COLUMN `image_id` BIGINT(20) NULL, + ADD CONSTRAINT `FK_m_staff_m_image` FOREIGN KEY (`image_id`) REFERENCES `m_image` (`id`); \ No newline at end of file