ushahidi / SwiftRiver-API

An API for external (third party) applications to post and consume data to/from SwiftRiver.

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

river_droplet_forms DB update script

ekala opened this issue · comments

The DDL for TABLE river_droplet_form in 2013_03_27_00_river_droplet_forms.sql:

CREATE TABLE IF NOT EXISTS river_droplet_form (
  id bigint NOT NULL AUTO_INCREMENT PRIMARY KEY,
  river_droplets_id bigint NOT NULL,
  form_id bigint NOT NULL,
  UNIQUE (rivers_droplets_id, form_id)
);

is different from the one in schema.sql

CREATE TABLE IF NOT EXISTS river_droplet_form (
  id bigint NOT NULL AUTO_INCREMENT PRIMARY KEY,
  drop_id bigint NOT NULL,
  form_id bigint NOT NULL,
  UNIQUE (drop_id, form_id)
);

Therefore, if an existing DB is updated using the update scripts, an exception is thrown whenever a drop fetch request is made