SET @OLD_UNIQUE_CHECKS=@@UNIQUE_CHECKS, UNIQUE_CHECKS=0;
SET @OLD_FOREIGN_KEY_CHECKS=@@FOREIGN_KEY_CHECKS, FOREIGN_KEY_CHECKS=0;
SET @OLD_SQL_MODE=@@SQL_MODE, SQL_MODE='TRADITIONAL';

DROP SCHEMA IF EXISTS `cytotech_db` ;
CREATE SCHEMA IF NOT EXISTS `cytotech_db` DEFAULT CHARACTER SET utf8 COLLATE utf8_general_ci ;
USE `cytotech_db` ;

-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_subject`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_subject` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_subject` (
  `idsubject` INT NOT NULL AUTO_INCREMENT ,
  `code` VARCHAR(3) NOT NULL ,
  `date_birth` DATE NOT NULL ,
  `gender` TINYINT(1) NOT NULL COMMENT '1=male, 2=female' ,
  `race` INT NOT NULL COMMENT '1=American Indian or Alaska Native; 2=Asian; 3=Black or African American; 4=Native Hawaiin or Other Pacific Islander; 5=White; 6=Unknown' ,
  `ethnicity` INT NOT NULL COMMENT '1=Hispanic or Latin; 2=Not Hispanic or latino; 3=Unknown' ,
  PRIMARY KEY (`idsubject`) )
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_crf_appl`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_crf_appl` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_crf_appl` (
  `idapplication` INT NOT NULL AUTO_INCREMENT ,
  `idsubject` INT NOT NULL ,
  `code` VARCHAR(4) NOT NULL ,
  `screening_date` DATE NOT NULL ,
  `date_consent` DATE NOT NULL ,
  `medical_history` TINYINT(1) NULL COMMENT '1=yes; 0=no' ,
  PRIMARY KEY (`idapplication`) ,
  INDEX `fk_sis_crf_appl_sis_subject` (`idsubject` ASC) ,
  CONSTRAINT `fk_sis_crf_appl_sis_subject`
    FOREIGN KEY (`idsubject` )
    REFERENCES `cytotech_db`.`sis_subject` (`idsubject` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_medical_history`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_medical_history` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_medical_history` (
  `idmed_history` INT NOT NULL AUTO_INCREMENT ,
  `idapplication` INT NOT NULL ,
  `description` TEXT NOT NULL ,
  `active` TINYINT(1) NOT NULL COMMENT '1=active; 0=not active' ,
  `date_create` DATETIME NOT NULL ,
  `date_update` DATETIME NULL ,
  PRIMARY KEY (`idmed_history`) ,
  INDEX `fk_sis_medical_history_sis_crf_appl1` (`idapplication` ASC) ,
  CONSTRAINT `fk_sis_medical_history_sis_crf_appl1`
    FOREIGN KEY (`idapplication` )
    REFERENCES `cytotech_db`.`sis_crf_appl` (`idapplication` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = big5;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_category`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_category` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_category` (
  `idcategory` INT NOT NULL AUTO_INCREMENT ,
  `name_category` VARCHAR(250) NOT NULL ,
  `alias` VARCHAR(250) NOT NULL ,
  `description` TEXT NULL ,
  `name_table` VARCHAR(200) NOT NULL ,
  PRIMARY KEY (`idcategory`) )
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_data_medical`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_data_medical` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_data_medical` (
  `iddm` INT NOT NULL AUTO_INCREMENT ,
  `idcategory` INT NOT NULL ,
  `name_field` TEXT NOT NULL ,
  `alias` VARCHAR(200) NULL ,
  `unit` VARCHAR(10) NULL ,
  `ordering` INT NULL ,
  `options` TEXT NULL ,
  PRIMARY KEY (`iddm`) ,
  INDEX `fk_sis_data_medical_sis_category1` (`idcategory` ASC) ,
  CONSTRAINT `fk_sis_data_medical_sis_category1`
    FOREIGN KEY (`idcategory` )
    REFERENCES `cytotech_db`.`sis_category` (`idcategory` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_data_general`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_data_general` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_data_general` (
  `iddata_general` INT NOT NULL AUTO_INCREMENT ,
  `idcategory` INT NOT NULL ,
  `name_field` TEXT NOT NULL ,
  `alias` VARCHAR(200) NULL ,
  `ordering` INT NULL ,
  PRIMARY KEY (`iddata_general`) ,
  INDEX `fk_sis_data_general_sis_category1` (`idcategory` ASC) ,
  CONSTRAINT `fk_sis_data_general_sis_category1`
    FOREIGN KEY (`idcategory` )
    REFERENCES `cytotech_db`.`sis_category` (`idcategory` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_criteria`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_criteria` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_criteria` (
  `idcriteria` INT NOT NULL AUTO_INCREMENT ,
  `idapplication` INT NOT NULL ,
  `iddata_general` INT NOT NULL ,
  `value` TINYINT NOT NULL COMMENT '1=Yes; 2=No; 3=N/A' ,
  `type` TINYINT(1) NOT NULL COMMENT '1=Inclusion; 2=Exclusion' ,
  PRIMARY KEY (`idcriteria`) ,
  INDEX `fk_sis_criteria_sis_crf_appl1` (`idapplication` ASC) ,
  CONSTRAINT `fk_sis_criteria_sis_crf_appl1`
    FOREIGN KEY (`idapplication` )
    REFERENCES `cytotech_db`.`sis_crf_appl` (`idapplication` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_appl_test`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_appl_test` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_appl_test` (
  `idappl_test` INT NOT NULL AUTO_INCREMENT ,
  `idapplication` INT NOT NULL ,
  `idtest` INT NOT NULL ,
  `date` DATE NOT NULL ,
  PRIMARY KEY (`idappl_test`) ,
  INDEX `fk_sis_appl_test_sis_crf_appl1` (`idapplication` ASC) ,
  CONSTRAINT `fk_sis_appl_test_sis_crf_appl1`
    FOREIGN KEY (`idapplication` )
    REFERENCES `cytotech_db`.`sis_crf_appl` (`idapplication` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_vital_signs`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_vital_signs` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_vital_signs` (
  `idvs` INT NOT NULL AUTO_INCREMENT ,
  `idappl_test` INT NOT NULL ,
  `iddm` INT NOT NULL ,
  `value` TEXT NOT NULL ,
  PRIMARY KEY (`idvs`) ,
  INDEX `fk_sis_vital_signs_sis_appl_test1` (`idappl_test` ASC) ,
  CONSTRAINT `fk_sis_vital_signs_sis_appl_test1`
    FOREIGN KEY (`idappl_test` )
    REFERENCES `cytotech_db`.`sis_appl_test` (`idappl_test` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_physical_exam`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_physical_exam` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_physical_exam` (
  `idpe` INT NOT NULL AUTO_INCREMENT ,
  `idappl_test` INT NOT NULL ,
  `iddm` INT NOT NULL ,
  `status` TINYINT(1) NOT NULL COMMENT '1=Normal; 2=Abnormal' ,
  `description` TEXT NULL ,
  PRIMARY KEY (`idpe`) ,
  INDEX `fk_sis_physical_exam_sis_appl_test1` (`idappl_test` ASC) ,
  CONSTRAINT `fk_sis_physical_exam_sis_appl_test1`
    FOREIGN KEY (`idappl_test` )
    REFERENCES `cytotech_db`.`sis_appl_test` (`idappl_test` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_tests`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_tests` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_tests` (
  `idtest` INT NOT NULL AUTO_INCREMENT ,
  `name_test` VARCHAR(250) NOT NULL ,
  `alias` VARCHAR(250) NOT NULL ,
  `ordering` INT NOT NULL ,
  PRIMARY KEY (`idtest`) )
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_detail_test`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_detail_test` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_detail_test` (
  `iddetail_test` INT NOT NULL AUTO_INCREMENT ,
  `idtest` INT NOT NULL ,
  `idcategory` INT NOT NULL ,
  `fields` VARCHAR(45) NULL ,
  PRIMARY KEY (`iddetail_test`) ,
  INDEX `fk_sis_detail_test_sis_tests1` (`idtest` ASC) ,
  INDEX `fk_sis_detail_test_sis_category1` (`idcategory` ASC) ,
  CONSTRAINT `fk_sis_detail_test_sis_tests1`
    FOREIGN KEY (`idtest` )
    REFERENCES `cytotech_db`.`sis_tests` (`idtest` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION,
  CONSTRAINT `fk_sis_detail_test_sis_category1`
    FOREIGN KEY (`idcategory` )
    REFERENCES `cytotech_db`.`sis_category` (`idcategory` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_pregnancy_test`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_pregnancy_test` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_pregnancy_test` (
  `idpreg_test` INT NOT NULL AUTO_INCREMENT ,
  `idappl_test` INT NOT NULL ,
  PRIMARY KEY (`idpreg_test`) ,
  INDEX `fk_sis_pregnancy_test_sis_appl_test1` (`idappl_test` ASC) ,
  CONSTRAINT `fk_sis_pregnancy_test_sis_appl_test1`
    FOREIGN KEY (`idappl_test` )
    REFERENCES `cytotech_db`.`sis_appl_test` (`idappl_test` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;


-- -----------------------------------------------------
-- Table `cytotech_db`.`sis_hematology_test`
-- -----------------------------------------------------
DROP TABLE IF EXISTS `cytotech_db`.`sis_hematology_test` ;

CREATE  TABLE IF NOT EXISTS `cytotech_db`.`sis_hematology_test` (
  `idhemat_test` INT NOT NULL AUTO_INCREMENT ,
  `idappl_test` INT NOT NULL ,
  `iddm` INT NOT NULL ,
  `results` TEXT NOT NULL ,
  `clinically_significant` TINYINT(1) NOT NULL COMMENT '1=yes; 0=no' ,
  `repeated` TINYINT(1) NOT NULL COMMENT '1=yes; 0=no' ,
  `description` TEXT NULL ,
  PRIMARY KEY (`idhemat_test`) ,
  INDEX `fk_sis_hematology_test_sis_appl_test1` (`idappl_test` ASC) ,
  CONSTRAINT `fk_sis_hematology_test_sis_appl_test1`
    FOREIGN KEY (`idappl_test` )
    REFERENCES `cytotech_db`.`sis_appl_test` (`idappl_test` )
    ON DELETE NO ACTION
    ON UPDATE NO ACTION)
ENGINE = MyISAM
DEFAULT CHARACTER SET = utf8
COLLATE = utf8_general_ci;



SET SQL_MODE=@OLD_SQL_MODE;
SET FOREIGN_KEY_CHECKS=@OLD_FOREIGN_KEY_CHECKS;
SET UNIQUE_CHECKS=@OLD_UNIQUE_CHECKS;

-- -----------------------------------------------------
-- Data for table `cytotech_db`.`sis_category`
-- -----------------------------------------------------
SET AUTOCOMMIT=0;
USE `cytotech_db`;
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Vital Signs', 'vital-signs', NULL, 'sis_vital_signs');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Physical Exam', 'physical-exam', NULL, 'sis_physical_exam');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Hematology Test', 'hematology-test', NULL, 'sis_hematology_test');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Pregnancy Test', 'pregnancy-test', NULL, 'sis_pregnancy_test');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Chemistry', 'chemistry', NULL, 'sis_chemistry');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Urinalysis', 'urinalysis', NULL, 'sis_urinalysis');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Toxicology', 'toxicology', NULL, 'sis_toxicology');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Inclusion Criteria', 'inclusion-criteria', NULL, 'sis_criteria');
INSERT INTO `cytotech_db`.`sis_category` (`idcategory`, `name_category`, `alias`, `description`, `name_table`) VALUES (NULL, 'Exclusion Criteria', 'exclusion-criteria', NULL, 'sis_criteria');

COMMIT;

-- -----------------------------------------------------
-- Data for table `cytotech_db`.`sis_data_medical`
-- -----------------------------------------------------
SET AUTOCOMMIT=0;
USE `cytotech_db`;
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Blood Pressure', 'blood-pressure', 'nmHg', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Pulse Rate', 'pulse-rate', 'bpm', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Respirations', 'respirations', 'rpm', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Oral Temperature', 'oral-temperature', 'C', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Height', 'height', 'cm', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Weight', 'weight', 'kg', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 1, 'Frame Size by Elbow Breadth', 'frame-size-by-elbow-breadth', NULL, NULL, 'Small/Medium/Large');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'General Appearance', 'general-appearance', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Skin', 'skin', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Head, Ears, Eyes, Nose, Throat', 'head-ears-eyes-nose-throat', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Chest and Lungs', 'chest-and-lunges', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Heart', 'heart', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Abdomen', 'abdomen', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Extremities', 'extremities', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Neurologic', 'neurologic', NULL, NULL, 'Normal/Abnormal');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 2, 'Other', 'other', NULL, NULL, 'l');
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'WBC Count', 'wbc-count', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'RBC Count', 'rbc-count', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Hemoglobin', 'hemoglobin', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Hematocrit', 'hematocrit', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'MCV', 'mcv', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'MCH', 'mch', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'MCHC', 'mchc', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'RDW', 'rdw', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Platelets', 'platelets', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Polys', 'polys', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Lymphs', 'lymphs', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Monocytes', 'monocytes', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Eos', 'eos', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 3, 'Basos', 'basos', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 4, 'PT/PTT/INR', 'pt/ptt/inr', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Glucose', 'glucose', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'BUN', 'bun', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Calcium', 'calcium', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Phosphorous', 'phosphorous', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Protein (total)', 'protein-total', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Bilirubin (total)', 'bilirubin-total', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Bilirubin (direct)', 'bilirubin-direct', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Albumin', 'albumin', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Alkaline phosphatase', 'alkaline-phosphatase', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'LDH', 'ldh', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'ALT', 'alt', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'AST', 'ast', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Cholesterol (total)', 'cholesterol-total', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Creatinine', 'creatinine', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Sodium', 'sodium', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Potassium', 'potassium', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Chloride', 'chloride', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'CO2', 'co2', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'GGT', 'ggt', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Serum Mg', 'serum-mg', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Total Cholesterol', 'total-cholesterol', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Tryglicerides', 'triglycerides', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'PT/PTT', 'pt/ptt', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'INR', 'inr', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 5, 'Others', 'others', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Specific gravity', 'specific-gravity', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'pH', 'pH', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Color', 'color', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Appearance', 'appearance', '', NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'WBC Esterase', 'wbc-esterase', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Protein', 'protein', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Glucose', 'glucose', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Ketones', 'ketones', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Occult Blood', 'occult-blood', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Bilirubin', 'bilirubin', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Urobilinogen', 'urobilinogen', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 6, 'Nitrite', 'nitrite', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 7, 'Urine toxicology screen', 'urine-toxicology-screen', NULL, NULL, NULL);
INSERT INTO `cytotech_db`.`sis_data_medical` (`iddm`, `idcategory`, `name_field`, `alias`, `unit`, `ordering`, `options`) VALUES (NULL, 7, 'Ethanol screen (may be part of tox screen above)', 'ethanol-screen', NULL, NULL, NULL);

COMMIT;

-- -----------------------------------------------------
-- Data for table `cytotech_db`.`sis_data_general`
-- -----------------------------------------------------
SET AUTOCOMMIT=0;
USE `cytotech_db`;
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject is willing to sign and able to understand the informed consent.', NULL, 1);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject has a histologically confirmed solid tumor that is metastatic or unresectable for which standard curative measures do not exist or are no longer effective.', NULL, 2);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject is at least 18 years old.', NULL, 3);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject has an ECOG (Eastern Cooperative Oncology Group) performance status <= 2.', NULL, 4);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject ha a life expectancy of greater than 3 months.', NULL, 5);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject has organ and marrow function as per Protocol requirements', NULL, 6);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'The subject is capable of understanding and complying with the protocol and has signed the informed consent document.', NULL, 7);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'If sexually active, the subjects is committed to use an accepted method of contraception during the course of the study.', NULL, 8);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'Female patients of achildbearing potential must have a negative pregnancy test at enrollment.', NULL, 9);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 8, 'If history of: more than 3 prior regimes of cytotoxic chemo; or more than 2 Biological regimens; or more than 3000 cGy to the marrow; has the CRC approved the subject?', NULL, 10);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Chemotherapy or radiotherapy within 4 weeks or has received nitrosoureas or mitomycin C within 6 weeks prior to entering the study.', NULL, 1);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'The subject has received anti-angiogenesis drugs within 4 weeks prior to entering the study.', NULL, 2);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'The subject has received radiation to >= 25% of his or her bone marrow  within 4 weeks of C31510IV treatment.', NULL, 3);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'The subject has received an investigational drug within 30 days of the first dose of study drug.', NULL, 4);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Adverse events still affect the subject due to investigational drugs or other medications administered more than 4 weeks prior enrollment.', NULL, 5);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject has uncontrolled intercurrent ilness that would limit compliance with study requirements.', NULL, 6);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is pregnant or lactating.', NULL, 7);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is HIV positive.', NULL, 8);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'The subject has an inability or unwillingness to abide by the study protocol or cooperate fully with the investigator or designee.', NULL, 9);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject have been taken Vitamin D3 supplements in the last 30 Days.', NULL, 10);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is currently on HMG-CoA Reductase Inhibitors.', NULL, 11);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is currently on digoxin or any type of Digitalis Alkaloids.', NULL, 12);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is currently on Colony Stimulating Factors.', NULL, 13);
INSERT INTO `cytotech_db`.`sis_data_general` (`iddata_general`, `idcategory`, `name_field`, `alias`, `ordering`) VALUES (NULL, 9, 'Subject is currently on Warfarin.', NULL, 14);

COMMIT;

-- -----------------------------------------------------
-- Data for table `cytotech_db`.`sis_tests`
-- -----------------------------------------------------
SET AUTOCOMMIT=0;
USE `cytotech_db`;
INSERT INTO `cytotech_db`.`sis_tests` (`idtest`, `name_test`, `alias`, `ordering`) VALUES (NULL, 'Screening Vital Signs and Physical Exam (within 21 Days of Dose 1)', 'screening-vital-signs-and-physical-exam-whithin-21-days-of-dose-1', 1);

COMMIT;

-- -----------------------------------------------------
-- Data for table `cytotech_db`.`sis_detail_test`
-- -----------------------------------------------------
SET AUTOCOMMIT=0;
USE `cytotech_db`;
INSERT INTO `cytotech_db`.`sis_detail_test` (`iddetail_test`, `idtest`, `idcategory`, `fields`) VALUES (NULL, 1, 1, '*');
INSERT INTO `cytotech_db`.`sis_detail_test` (`iddetail_test`, `idtest`, `idcategory`, `fields`) VALUES (NULL, 1, 2, '*');

COMMIT;
