--
-- Database setup file

-- DATA
-- dataid integer primary key autoincrement,
create table if not exists DATA(
   date integer not null,
   data_submissionid integer,
   data_created varchar(100) null,
   data_name varchar(100) null,
   data_email varchar(100) null,
   data_museum varchar(255) not null,
   data_position varchar(100) null,
   data_sharedata varchar(10) null,
   data_corrfound1 varchar(10) null,
   data_date varchar(100) null,
   data_instrumentid varchar(100) not null,
   data_type varchar(255) null,
   data_family varchar(255) null,
   data_proddate varchar(100) null,
   data_prodplace varchar(100) null,
   data_prodadd varchar(255) null,
   data_metaltype1 varchar(100) null,
   data_organictype1 varchar(100) null,
   data_metalloc1 varchar(100) null,
   data_organicloc1 varchar(100) null,
   data_metaldiscolor1 integer,
   data_metalsurfalter1 integer,
   data_metalstructdam1 integer,
   data_metalnochange1 integer,
   data_organicdiscolor1 integer,
   data_organicsurfalter1 integer,
   data_organicstructdam1 integer,
   data_organicnochange1 integer,
   data_metalcolor1 varchar(100) null,
   data_conditioncp1 integer,
   data_conditionoverall integer,
   data_metalearlierex integer,
   data_metalearliertreat integer,
   data_metalearliertreatnov integer,
   data_organicearlierex integer,
   data_organicearliertreat integer,
   data_organicearliertreatnov integer,
   data_earlierwaterdam varchar(10) null,
   data_metalcorrindcp varchar(10) null,
   data_rh integer,
   data_corrfound2 varchar(10) null,
   data_metaltype2 varchar(100) null,
   data_organictype2 varchar(100) null,
   data_metalloc2 varchar(100) null,
   data_organicloc2 varchar(100) null,
   data_metaldiscolor2 integer,
   data_metalsurfalter2 integer,
   data_metalstructdam2 integer,
   data_metalnochange2 integer,
   data_organicdiscolor2 integer,
   data_organicsurfalter2 integer,
   data_organicstructdam2 integer,
   data_organicnochange2 integer,
   data_metalcolor2 varchar(100) null,
   data_conditioncp2 integer,
   data_corrfound3 varchar(10) null,
   data_metaltype3 varchar(100) null,
   data_organictype3 varchar(100) null,
   data_metalloc3 varchar(100) null,
   data_organicloc3 varchar(100) null,
   data_metaldiscolor3 integer,
   data_metalsurfalter3 integer,
   data_metalstructdam3 integer,
   data_metalnochange3 integer,
   data_organicdiscolor3 integer,
   data_organicsurfalter3 integer,
   data_organicstructdam3 integer,
   data_organicnochange3 integer,
   data_metalcolor3 varchar(100) null,
   data_conditioncp3 integer,
   data_corrfound4 varchar(10) null,
   data_metaltype4 varchar(100) null,
   data_organictype4 varchar(100) null,
   data_metalloc4 varchar(100) null,
   data_organicloc4 varchar(100) null,
   data_metaldiscolor4 integer,
   data_metalsurfalter4 integer,
   data_metalstructdam4 integer,
   data_metalnochange4 integer,
   data_organicdiscolor4 integer,
   data_organicsurfalter4 integer,
   data_organicstructdam4 integer,
   data_organicnochange4 integer,
   data_metalcolor4 varchar(100) null,
   data_conditioncp4 integer,
   data_comments varchar(255) null,
   data_answertime integer,
   primary key(data_museum,data_instrumentid));
