-- Deploy gaia:api_2015_11_27_api_organization_image_create_table to mysql

BEGIN;
CREATE TABLE `api_organization_image` (
    `id` integer AUTO_INCREMENT NOT NULL PRIMARY KEY,
    `image_url` varchar(256) NOT NULL,
    `doctor_id` varchar(100) NOT NULL,
    `hospital_id` varchar(100) NOT NULL
);
ALTER TABLE `api_organization_image` ADD CONSTRAINT `doctor_id_refs_id_908b92e9` FOREIGN KEY (`doctor_id`) REFERENCES `api_doctor` (`id`);
ALTER TABLE `api_organization_image` ADD CONSTRAINT `hospital_id_refs_id_ff32d54c` FOREIGN KEY (`hospital_id`) REFERENCES `api_hospital` (`id`);
-- XXX Add DDLs here.

COMMIT;

