diff --git a/SQL/0000-00-05-ElectrophysiologyTables.sql b/SQL/0000-00-05-ElectrophysiologyTables.sql index 8e73716f41c..cb5adbd233e 100644 --- a/SQL/0000-00-05-ElectrophysiologyTables.sql +++ b/SQL/0000-00-05-ElectrophysiologyTables.sql @@ -205,6 +205,19 @@ CREATE TABLE `physiological_task_event` ( ) ENGINE=InnoDB DEFAULT CHARSET=utf8; +-- Create `physiological_task_event_opt` table +-- tracks additional events from bids archives +CREATE TABLE `physiological_task_event_opt` ( + `ID` int(10) unsigned NOT NULL AUTO_INCREMENT, + `PhysiologicalTaskEventID` int(10) unsigned NOT NULL, + `TaskName` varchar(50) NOT NULL, + `TaskValue` varchar(255) NULL, + PRIMARY KEY (`ID`), + CONSTRAINT `FK_event_task_opt` + FOREIGN KEY (`PhysiologicalTaskEventID`) + REFERENCES `physiological_task_event` (`PhysiologicalTaskEventID`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8; + -- Create physiological_archive which will store archives of all the files for -- Front-end download diff --git a/SQL/New_patches/2022-11-22-eeg-additional-events-table.sql b/SQL/New_patches/2022-11-22-eeg-additional-events-table.sql new file mode 100644 index 00000000000..b8bf0db0efb --- /dev/null +++ b/SQL/New_patches/2022-11-22-eeg-additional-events-table.sql @@ -0,0 +1,12 @@ +-- Create `physiological_task_event_opt` table +-- tracks additional events from bids archives +CREATE TABLE `physiological_task_event_opt` ( + `ID` int(10) unsigned NOT NULL AUTO_INCREMENT, + `PhysiologicalTaskEventID` int(10) unsigned NOT NULL, + `TaskName` varchar(50) NOT NULL, + `TaskValue` varchar(255) NULL, + PRIMARY KEY (`ID`), + CONSTRAINT `FK_event_task_opt` + FOREIGN KEY (`PhysiologicalTaskEventID`) + REFERENCES `physiological_task_event` (`PhysiologicalTaskEventID`) +) ENGINE=InnoDB DEFAULT CHARSET=utf8; \ No newline at end of file