 --    STOPPED VARCHAR(255));
 
 LOAD DATA LOCAL INFILE 'DATETIMEEVENTS_DATA_TABLE.csv' INTO TABLE DATETIMEEVENTS
-   FIELDS TERMINATED BY ',' ESCAPED BY '\\' OPTIONALLY ENCLOSED BY '"' 
+   FIELDS TERMINATED BY ',' ESCAPED BY '\\' OPTIONALLY ENCLOSED BY '"'
    LINES TERMINATED BY '\n'
    IGNORE 1 LINES
    (@ROW_ID,@SUBJECT_ID,@HADM_ID,@ICUSTAY_ID,@ITEMID,@CHARTTIME,@STORETIME,@CGID,@VALUE,@UOM,@WARNING,@ERROR,@RESULTSTATUS,@STOPPED)

-- --------------------------------------------------------

  CREATE TABLE SERVICES
   (	ROW_ID BIGINT, 
	SUBJECT_ID INT, 
	HADM_ID INT, 
	TRANSFERTIME DATETIME, 
	PREV_SERVICE VARCHAR(20), 
	CURR_SERVICE VARCHAR(20)
   ) ;


-- --------------------------------------------------------

  CREATE TABLE NOTEEVENTS
   (	ROW_ID BIGINT,
	RECORD_ID INT,
	SUBJECT_ID INT,
	HADM_ID INT,
	CHARTDATE DATETIME,
	CATEGORY VARCHAR(50),
	DESCRIPTION VARCHAR(255),
	CGID INT,
	ISERROR CHAR(1),
	TEXT TEXT
   ) ;

