ctakes-commits mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From vjapa...@apache.org
Subject svn commit: r1551254 [10/26] - in /ctakes/branches/ytex: ctakes-ytex-res/ ctakes-ytex-res/.settings/ ctakes-ytex-res/src/ ctakes-ytex-res/src/main/ ctakes-ytex-res/src/main/resources/ ctakes-ytex-res/src/main/resources/org/ ctakes-ytex-res/src/main/res...
Date Mon, 16 Dec 2013 16:30:40 GMT
Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/create_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/create_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/create_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/create_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,52 @@
+-- We assume the metadata about documents (patient id, date) come from
+-- some table in your database.  modify this view to join with that table
+-- and get this info
+create view v_document as
+select analysis_batch, document_id, doc_text, instance_id, null patient_id, null doc_date, null doc_title, null document_type_name
+from document;
+
+
+create view v_annotation
+AS
+SELECT anno.*, ur.uima_type_name, substring(doc.doc_text, anno.span_begin+1, anno.span_end-anno.span_begin) anno_text, doc.analysis_batch
+FROM anno_base AS anno 
+INNER JOIN document AS doc ON doc.document_id = anno.document_id
+INNER JOIN ref_uima_type AS ur on ur.uima_type_id = anno.uima_type_id
+;
+
+
+-- this view gives the document info, cui info, and sentence info in which a cui is found.
+create view v_document_cui_sent
+as
+SELECT
+  da.anno_base_id,
+  d.analysis_batch,
+  da.document_id,
+  ne.polarity,
+  o.code,
+  o.cui,
+  substr(d.doc_text, da.span_begin+1, da.span_end-da.span_begin) cui_text,
+  substr(d.doc_text, s.span_begin+1, s.span_end-s.span_begin) sentence_text,
+  o.disambiguated,
+  null patient_id,
+  null doc_date,
+  null doc_title,
+  null document_type_name
+FROM anno_base da
+INNER JOIN anno_named_entity  ne ON da.anno_base_id = ne.anno_base_id
+INNER JOIN anno_ontology_concept  o ON o.anno_base_id = ne.anno_base_id
+inner join anno_contain ac on da.anno_base_id = ac.child_anno_base_id
+INNER join anno_base s
+  on ac.parent_anno_base_id = s.anno_base_id
+  and s.uima_type_id in (select uima_type_id from ref_uima_type where uima_type_name = 'edu.mayo.bmi.uima.core.type.textspan.Sentence')
+INNER JOIN document d on da.document_id = d.document_id
+;
+
+CREATE VIEW v_document_ontoanno
+AS
+SELECT d.document_id, da.span_begin, da.span_end, ne.polarity, o.code, o.cui, d.analysis_batch, o.disambiguated
+FROM document AS d INNER JOIN
+anno_base AS da ON d.document_id = da.document_id INNER JOIN
+anno_named_entity AS ne ON da.anno_base_id = ne.anno_base_id INNER JOIN
+anno_ontology_concept AS o ON o.anno_base_id = ne.anno_base_id
+;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/delete_orphan.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/delete_orphan.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/delete_orphan.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/delete_orphan.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,83 @@
+delete anno_base 
+from anno_base 
+left join document
+	on anno_base.document_id = document.document_id
+where document.document_id is null
+; 
+
+delete anno_sentence 
+from anno_sentence 
+left join anno_base
+	on anno_base.anno_base_id = anno_sentence.anno_base_id
+where anno_base.anno_base_id is null
+; 
+
+delete anno_date
+from anno_date 
+left join anno_base
+	on anno_base.anno_base_id = anno_date.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_named_entity
+from anno_named_entity 
+left join anno_base
+	on anno_base.anno_base_id = anno_named_entity.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_source_doc_info
+from anno_source_doc_info 
+left join anno_base
+	on anno_base.anno_base_id = anno_source_doc_info.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_docdate
+from anno_docdate 
+left join anno_base
+	on anno_base.anno_base_id = anno_docdate.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_dockey
+from anno_dockey 
+left join anno_base
+	on anno_base.anno_base_id = anno_dockey.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_segment
+from anno_segment 
+left join anno_base
+	on anno_base.anno_base_id = anno_segment.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_num_token
+from anno_num_token 
+left join anno_base
+	on anno_base.anno_base_id = anno_num_token.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_ontology_concept
+from anno_ontology_concept 
+left join anno_base
+	on anno_base.anno_base_id = anno_ontology_concept.anno_base_id
+where anno_base.anno_base_id is null
+;
+
+delete anno_umls_concept
+from anno_umls_concept 
+left join anno_ontology_concept
+	on anno_umls_concept.anno_ontology_concept_id = anno_ontology_concept.anno_ontology_concept_id
+where anno_ontology_concept.anno_ontology_concept_id is null
+;
+
+delete anno_word_token
+from anno_word_token 
+left join anno_base
+	on anno_base.anno_base_id = anno_word_token.anno_base_id
+where anno_base.anno_base_id is null
+;
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_document.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_document.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_document.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_document.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,32 @@
+-- drop 'operational' data
+-- legacy begin
+drop table if exists document_class;
+drop table if exists anno_word_token;
+drop table if exists anno_base_token;
+drop table if exists anno_num_token;
+drop table if exists anno_umls_concept; 
+drop table if exists anno_source_doc_info;
+drop table if exists anno_umls_concept;
+-- legacy end
+drop table if exists anno_mm_cuiconcept;
+drop table if exists anno_mm_candidate;
+drop table if exists anno_mm_acronym;
+drop table if exists anno_mm_utterance;
+drop table if exists anno_mm_negation;
+drop table if exists fracture_demo;
+drop table if exists anno_drug_mention;
+drop table if exists anno_markable;
+drop table if exists anno_treebank_node;
+drop table if exists anno_link;
+drop table if exists anno_contain;
+drop table if exists anno_num_token;
+drop table if exists anno_token;
+drop table if exists anno_segment;
+drop table if exists anno_ontology_concept;
+drop table if exists anno_named_entity;
+drop table if exists anno_med_event;
+drop table if exists anno_sentence;
+drop table if exists anno_date;
+drop table if exists anno_base;
+drop table if exists document;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_reference.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_reference.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_reference.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_reference.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,7 @@
+-- drop 'reference' data
+drop table if exists hibernate_sequences;
+drop table if exists anno_base_sequence;
+drop table if exists ref_uima_type;
+drop table if exists ref_named_entity_regex;
+drop table if exists ref_segment_regex;
+drop table if exists ref_stopword;
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/drop_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,11 @@
+drop table if exists v_document;
+drop table if exists v_annotation;
+drop table if exists v_document_cui_sent;
+drop table if exists v_document_ontoanno;
+
+drop view if exists v_document;
+drop view if exists v_annotation;
+drop view if exists v_document_cui_sent;
+drop view if exists v_document_ontoanno;
+
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/fracture_demo.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/fracture_demo.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/fracture_demo.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/uima/fracture_demo.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1 @@
+update fracture_demo set note_text = replace(note_text, '<br/>', CHAR(10));
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_indices.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_indices.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_indices.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_indices.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,2 @@
+create index IX_fword on umls_aui_fword (fword);
+create index IX_fstem on umls_aui_fword (fstem);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,9 @@
+
+create table umls_aui_fword (
+	aui varchar(10) not null primary key,
+	fword varchar(70) not null,
+	fstem varchar(70) null,
+	tok_str varchar(250) not null,
+	stem_str varchar(250) null
+) engine=myisam, CHARACTER SET utf8;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/create_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,8 @@
+create table v_snomed_fword_lookup (
+  cui char(8) not null,
+  tui char(8) null,
+  fword varchar(70) not null,
+  fstem varchar(70) null,
+  tok_str varchar(250) not null,
+  stem_str varchar(250) null
+ ) engine=myisam, comment 'umls lookup table, created from umls_aui_fword and mrconso' ;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1 @@
+drop table if exists umls_aui_fword;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/drop_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,3 @@
+-- for backwards compatability, drop the view if it's there
+drop view if exists v_snomed_fword_lookup;
+drop table if exists v_snomed_fword_lookup;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/import_umls.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/import_umls.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/import_umls.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/import_umls.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,38 @@
+-- this is only executed if you don't have umls installed in your db 
+-- load the umls mrconso table from a dump file.
+-- the following was copied directly from the umls load script.
+-- intentionally do not drop MRCONSO - if it exists then we should use it 
+-- instead of overwriting it
+CREATE TABLE MRCONSO (
+    CUI	char(8) NOT NULL,
+    LAT	char(3) NOT NULL,
+    TS	char(1) NOT NULL,
+    LUI	varchar(10) NOT NULL,
+    STT	varchar(3) NOT NULL,
+    SUI	varchar(10) NOT NULL,
+    ISPREF	char(1) NOT NULL,
+    AUI	varchar(9) NOT NULL,
+    SAUI	varchar(50),
+    SCUI	varchar(50),
+    SDUI	varchar(50),
+    SAB	varchar(20) NOT NULL,
+    TTY	varchar(20) NOT NULL,
+    CODE	varchar(50) NOT NULL,
+    STR	text NOT NULL,
+    SRL	int unsigned NOT NULL,
+    SUPPRESS	char(1) NOT NULL,
+    CVF	int unsigned
+) CHARACTER SET utf8;
+
+ALTER TABLE MRCONSO ADD CONSTRAINT X_MRCONSO_PK  PRIMARY KEY BTREE (AUI);
+
+CREATE TABLE MRSTY (
+    CUI	char(8) NOT NULL,
+    TUI	char(4) NOT NULL,
+    STN	varchar(100) NOT NULL,
+    STY	varchar(50) NOT NULL,
+    ATUI	varchar(11) NOT NULL,
+    CVF	int unsigned
+) CHARACTER SET utf8;
+
+ALTER TABLE MRSTY ADD CONSTRAINT X_MRSTY_PK  PRIMARY KEY BTREE (ATUI);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_umls.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_umls.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_umls.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_umls.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,20 @@
+CREATE INDEX X_MRCONSO_CUI ON MRCONSO(CUI);
+
+CREATE INDEX X_MRCONSO_SUI ON MRCONSO(SUI);
+
+CREATE INDEX X_MRCONSO_LUI ON MRCONSO(LUI);
+
+CREATE INDEX X_MRCONSO_CODE ON MRCONSO(CODE);
+
+CREATE INDEX X_MRCONSO_SAB_TTY ON MRCONSO(SAB,TTY);
+
+CREATE INDEX X_MRCONSO_SCUI ON MRCONSO(SCUI);
+
+CREATE INDEX X_MRCONSO_SDUI ON MRCONSO(SDUI);
+
+CREATE INDEX X_MRCONSO_STR ON MRCONSO(STR(255));
+
+CREATE INDEX X_MRSTY_CUI ON MRSTY(CUI);
+
+CREATE INDEX X_MRSTY_STY ON MRSTY(STY);
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/index_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,3 @@
+create index idx_fword on v_snomed_fword_lookup (fword);
+create index idx_fstem on v_snomed_fword_lookup (fstem);
+create index idx_cui on v_snomed_fword_lookup (cui);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/insert_view.template.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/insert_view.template.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/insert_view.template.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/insert_view.template.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,37 @@
+-- create first word lookup table
+-- the cTAKES Assertion annotator expects the TUI of a concept
+-- a CUI can have multiple TUIs, and which one to pick is somewhat arbitrary
+-- replace @UMLS_SCHEMA@ with the appropriate value
+insert into v_snomed_fword_lookup (cui, tui, fword, fstem, tok_str, stem_str)
+select mrc.cui, t.tui, c.fword, c.fstem, c.tok_str, c.stem_str
+from umls_aui_fword c
+inner join @UMLS_SCHEMA@.MRCONSO mrc on c.aui = mrc.aui and mrc.SAB in ( 'SNOMEDCT', 'RXNORM')
+inner join 
+(
+	select cui, min(tui) tui
+	from @UMLS_SCHEMA@.MRSTY sty
+	where sty.tui in
+	(
+    /* diseasesAndDisordersTuis */
+    'T019', 'T020', 'T037', 'T046', 'T047', 'T048', 'T049', 'T050', 
+      'T190', 'T191', 'T033',
+    /* signAndSymptomTuis */
+    'T184',
+    /* anatomicalSitesTuis */
+    'T017', 'T029', 'T023', 'T030', 'T031', 'T022', 'T025', 'T026',
+        'T018', 'T021', 'T024',
+    /* medicationsAndDrugsTuis */
+     'T116', 'T195', 'T123', 'T122', 'T118', 'T103', 'T120', 'T104',
+        'T200', 'T111', 'T196', 'T126', 'T131', 'T125', 'T129', 'T130',
+        'T197', 'T119', 'T124', 'T114', 'T109', 'T115', 'T121', 'T192',
+        'T110', 'T127',
+	/* proceduresTuis */
+    'T060', 'T065', 'T058', 'T059', 'T063', 'T062', 'T061',
+    /* deviceTuis */
+    'T074', 'T075',
+    /* laboratoryTuis */
+    'T059'
+	)
+	group by cui
+) t on t.cui = mrc.cui
+;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/readme.txt
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/readme.txt?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/readme.txt (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/umls/readme.txt Mon Dec 16 16:30:30 2013
@@ -0,0 +1,116 @@
+# get all the umls_aui_fword data
+mysql --skip-column-names --user=ytex --password=ytex --database=ytex -e "select * from umls_aui_fword" > umls_aui_fword.txt
+
+
+# get the demo data
+mysql --skip-column-names --user=ytex --password=ytex --database=ytex -e "select concat(CUI,'|',TUI,'|',STN,'|',STY,'|',ATUI,'|',coalesce(CVF,'')) from sctrxnorm2011ab.MRSTY mst inner join (select distinct code from anno_ontology_concept) c on mst.cui = c.code" > E:\projects\ytex\data\umls\MRSTY.RRF 
+mysql --skip-column-names --user=ytex --password=ytex --database=ytex -e "select concat(CUI,'|',LAT,'|',TS,'|',LUI,'|',STT,'|',SUI,'|',ISPREF,'|',AUI,'|',coalesce(SAUI,''),'|',coalesce(SCUI,''),'|',coalesce(SDUI,''),'|',SAB,'|',TTY,'|',mrc.CODE,'|',STR,'|',SRL,'|',SUPPRESS,'|',coalesce(CVF,'')) from sctrxnorm2011ab.MRCONSO mrc inner join ( select distinct code from anno_ontology_concept ) c on mrc.cui = c.code and lat = 'ENG'" > E:\projects\ytex\data\umls\MRCONSO.RRF 
+mysql --skip-column-names --user=ytex --password=ytex --database=ytex -e "select fw.* from umls_aui_fword fw inner join sctrxnorm2011ab.mrconso mrc on fw.aui = mrc.aui inner join (select distinct code from anno_ontology_concept) c on c.code = mrc.cui" > E:\projects\ytex\data\umls\umls_aui_fword.txt 
+
+demo contains only umls concepts for fracture demo
+
+mysql demo data:
+select
+CUI,
+TUI,
+STN,
+STY,
+ATUI,
+coalesce(CVF,'')
+into outfile 'E:/projects/ytex/data/mysql/umls/MRSTY.RRF'
+fields terminated by '|' ESCAPED BY '' lines terminated by '\r\n'
+from umls.MRSTY mst
+inner join (select distinct code from anno_ontology_concept) c on mst.cui = c.code
+;
+
+
+select CUI,
+LAT,
+TS,
+LUI,
+STT,
+SUI,
+ISPREF,
+AUI,
+coalesce(SAUI,''),
+coalesce(SCUI,''),
+coalesce(SDUI,''),
+SAB,
+TTY,
+mrc.CODE,
+STR,
+SRL,
+SUPPRESS,
+coalesce(CVF,'')
+into outfile 'E:/projects/ytex/data/mysql/umls/MRCONSO.RRF'
+fields terminated by '|' ESCAPED BY '' lines terminated by '\r\n'
+from umls.MRCONSO mrc
+inner join
+(
+select distinct code from anno_ontology_concept
+) c on mrc.cui = c.code
+where mrc.sab in ( 'SNOMEDCT', 'RXNORM', 'SRC')
+and lat = 'ENG'
+;
+
+select fw.*
+into outfile 'E:/projects/ytex/data/mysql/umls/umls_aui_fword.txt'
+from umls_aui_fword fw
+inner join umls.mrconso mrc on fw.aui = mrc.aui and mrc.sab in ( 'SNOMEDCT', 'RXNORM', 'SRC')
+inner join
+(
+select distinct code from anno_ontology_concept
+) c on c.code = mrc.cui;
+
+
+mysql real data:
+select CUI,
+LAT,
+TS,
+LUI,
+STT,
+SUI,
+ISPREF,
+AUI,
+coalesce(SAUI,''),
+coalesce(SCUI,''),
+coalesce(SDUI,''),
+SAB,
+TTY,
+mrc.CODE,
+STR,
+SRL,
+SUPPRESS,
+coalesce(CVF,'')
+into outfile 'E:/projects/ytex-umls/mysql/MRCONSO.RRF'
+fields terminated by '|' ESCAPED BY '' lines terminated by '\r\n'
+from umls.MRCONSO mrc
+where SAB in ('SNOMEDCT', 'RXNORM', 'SRC')
+and LAT = 'ENG'
+;
+
+
+select
+sty.CUI,
+TUI,
+STN,
+STY,
+ATUI,
+coalesce(CVF,'')
+into outfile 'E:/projects/ytex-umls/mysql/MRSTY.RRF'
+fields terminated by '|' ESCAPED BY '' lines terminated by '\r\n'
+from umls.MRSTY sty
+inner join
+	(
+	select distinct cui
+	from umls.MRCONSO
+	where SAB in ('SNOMEDCT', 'RXNORM', 'SRC')
+	) c on sty.cui = c.cui
+;
+
+select fw.*
+into outfile 'E:/projects/ytex-umls/mysql/umls_aui_fword.txt'
+from umls_aui_fword fw
+inner join umls.mrconso mrc on fw.aui = mrc.aui and mrc.sab in ('SNOMEDCT', 'RXNORM', 'SRC')
+;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/util/update_anno_contain.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/util/update_anno_contain.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/util/update_anno_contain.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/mysql/util/update_anno_contain.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,27 @@
+-- Fill in the anno_contain table with all containment relationships
+
+-- clear out existing relationships
+delete ac
+from anno_contain ac
+inner join anno_base ab on ac.parent_anno_base_id = ab.anno_base_id
+inner join document d on d.document_id = ab.document_id
+where d.analysis_batch = 'i2b2.2008'
+;
+
+-- insert new relationships
+insert into anno_contain (parent_anno_base_id, parent_uima_type_id, child_anno_base_id, child_uima_type_id)
+select p.anno_base_id, p.uima_type_id, c.anno_base_id, c.uima_type_id
+from document d
+inner join anno_base c on c.document_id = d.document_id
+inner join anno_base p
+	on p.document_id = d.document_id
+	and p.span_begin <= c.span_begin
+	and p.span_end >= c.span_end
+where analysis_batch = 'i2b2.2008'
+-- prevent trivial containment - same type, same span 
+and p.span_begin <> c.span_begin
+and p.span_end <> c.span_end
+and p.uima_type_id <> c.uima_type_id
+and p.span_begin is not null
+and c.span_begin is not null
+;
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,36 @@
+create sequence feature_eval_sequence;
+create sequence feature_rank_sequence;
+create sequence feature_parchd_sequence;
+
+create table feature_eval (
+  feature_eval_id int not null primary key,
+  corpus_name varchar2(50) not null ,
+  featureset_name varchar2(50) default ' ' not null ,
+  label varchar2(50) default ' '  not null ,
+  cv_fold_id int default 0  not null ,
+  param1 DOUBLE PRECISION default 0 not null ,
+  param2 varchar2(50) default ' ' not null ,
+  type varchar2(50) not null
+);
+create unique index nk_feature_eval on feature_eval(corpus_name, featureset_name, label, cv_fold_id, param1, param2, type);
+create index ix_feature_eval on feature_eval (corpus_name, cv_fold_id, type);
+
+create table  feature_rank (
+  feature_rank_id int not null primary key,
+  feature_eval_id int not null ,
+  feature_name varchar2(50) not null ,
+  evaluation DOUBLE PRECISION default 0 not null ,
+  rank int default 0 not null ,
+  foreign key (feature_eval_id) references feature_eval (feature_eval_id) ON DELETE CASCADE
+) ;
+create unique index nk_feature_name on  feature_rank(feature_eval_id, feature_name);
+create index ix_feature_rank  on  feature_rank(feature_eval_id, rank);
+create index ix_feature_evaluation  on  feature_rank(feature_eval_id, evaluation);
+
+
+CREATE TABLE feature_parchd (
+  feature_parchd_id int NOT NULL primary key,
+  par_feature_rank_id int NOT NULL ,
+  chd_feature_rank_id int NOT NULL
+);
+create UNIQUE index NK_feature_parent on feature_parchd(par_feature_rank_id,chd_feature_rank_id);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables_trg.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables_trg.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables_trg.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/create_tables_trg.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,25 @@
+-- insert triggers to generate primary keys from sequence
+create trigger trg_feature_eval before insert on feature_eval
+for each row
+when (new.feature_eval_id is null)
+begin
+ select feature_eval_sequence.nextval into :new.feature_eval_id from dual;
+end;
+/
+
+
+create trigger trg_feature_rank before insert on feature_rank
+for each row
+when (new.feature_rank_id is null)
+begin
+ select feature_rank_sequence.nextval into :new.feature_rank_id from dual;
+end;
+/
+
+create trigger trg_feature_parchd before insert on feature_parchd
+for each row
+when (new.feature_parchd_id is null)
+begin
+ select feature_parchd_sequence.nextval into :new.feature_parchd_id from dual;
+end;
+/

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/drop_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/drop_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/drop_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/kernel/drop_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,19 @@
+drop index nk_feature_eval;
+drop index ix_feature_eval;
+drop trigger trg_feature_eval;
+
+drop index nk_feature_name;
+drop index ix_feature_rank;
+drop index ix_feature_evaluation;
+drop trigger trg_feature_rank;
+
+drop index NK_feature_parent;
+drop trigger trg_feature_parchd;
+
+drop sequence feature_eval_sequence;
+drop sequence feature_rank_sequence;
+drop sequence feature_parchd_sequence;
+
+drop table feature_parchd;
+drop table feature_rank;
+drop table feature_eval;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/test/createdb.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/test/createdb.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/test/createdb.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/test/createdb.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,7 @@
+alter session set container=PDBORCL;
+create tablespace TBS_YTEX_TEST datafile 'C:/code/data/oradata/orcl/TBS_YTEX_TEST.dbf' size 1M autoextend on online;
+create user ytex_test identified by ytex_test default tablespace TBS_YTEX_TEST;
+grant connect, resource to ytex_test;
+grant create materialized view to ytex_test;
+grant create view to ytex_test;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,265 @@
+-- create sequence document_id_sequence;
+-- create sequence anno_base_id_sequence;
+create sequence anno_onto_concept_id_sequence;
+create sequence anno_contain_id_sequence;
+create sequence anno_link_id_sequence;
+create sequence demo_note_id_sequence;
+create sequence anno_mm_cuiconcept_id_sequence;
+
+CREATE TABLE document(
+	document_id int  NOT NULL,
+	instance_id NUMBER(19) default 0 not null,
+	instance_key varchar2(256) null,
+	analysis_batch varchar2(50) default ' ' NOT NULL,
+	cas blob NULL,
+	doc_text clob NULL,
+	CONSTRAINT PK_document PRIMARY KEY
+	(
+		document_id
+	)	
+) 
+;
+
+CREATE INDEX IX_document_analysis_batch ON document 
+(
+	analysis_batch,
+	document_id
+)
+;
+
+CREATE INDEX IX_instance_id ON document 
+(
+	instance_id
+)
+;
+
+CREATE INDEX IX_instance_key ON document 
+(
+	instance_key
+)
+;
+
+create table anno_base (
+	anno_base_id int  not null,
+	document_id int not null,
+	span_begin int,
+	span_end int,
+	uima_type_id int not null,
+	primary key (anno_base_id),
+	foreign key (document_id) references document (document_id) ON DELETE CASCADE,
+	foreign key (uima_type_id) references ref_uima_type (uima_type_id)
+)
+;
+
+CREATE INDEX IX_docanno_doc ON anno_base (document_id)
+;
+
+
+create table anno_sentence (
+	anno_base_id int not null,
+	sentenceNumber int,
+	segmentId varchar2(20),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id)  ON DELETE CASCADE
+);
+
+create table anno_named_entity (
+	anno_base_id int not null,
+	discoveryTechnique int,
+	status int,
+	polarity int,
+	uncertainty int,
+	conditional numeric(1),
+	generic numeric(1),
+	typeID int,
+	confidence float,
+	segmentID varchar2(20),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id)  ON DELETE CASCADE
+);
+
+create table anno_med_event (
+	anno_base_id int,
+	discoveryTechnique int,
+	status int,
+	polarity int,
+	uncertainty int,
+	conditional numeric(1),
+	generic numeric(1),
+	typeID int,
+	confidence float,
+	segmentID varchar2(20),
+	freqNumber varchar2(10),
+	freqUnit varchar2(10),
+	strengthNumber varchar2(10),
+	strengthUnit varchar2(10),
+	"change" varchar2(10),
+	dosage varchar2(10),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id)  ON DELETE CASCADE
+);
+
+create table anno_ontology_concept (
+	anno_ontology_concept_id int  not null,
+	anno_base_id int not null,
+	code varchar2(20),
+	cui char(8),
+	disambiguated numeric(1) default 0 not null,
+	primary key (anno_ontology_concept_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id)  ON DELETE CASCADE
+);
+
+CREATE INDEX IX_ontology_concept_code ON anno_ontology_concept (code)
+;
+
+
+CREATE TABLE anno_segment(
+	anno_base_id int NOT NULL,
+	id varchar2(20) NULL,
+	PRIMARY KEY (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id)  ON DELETE CASCADE
+)
+;
+
+
+CREATE INDEX IX_segment_anno_seg ON anno_segment
+(
+	id 
+)
+;
+
+
+-- mapped to BaseToken
+create table anno_token (
+	anno_base_id int NOT NULL,
+	tokenNumber int,
+	normalizedForm varchar2(20),
+	partOfSpeech varchar2(5),
+	coveredText varchar2(20) null,
+	capitalization int default 0 not null,
+	numPosition int default 0 not null,
+	suggestion varchar2(20),
+	canonicalForm varchar2(20),
+	negated NUMERIC(1) default 0 not null,
+	possible NUMERIC(1) default 0 not null,
+	PRIMARY KEY
+	(
+		anno_base_id 
+	),
+	foreign key (anno_base_id)
+		references anno_base(anno_base_id)
+		ON DELETE CASCADE
+) ;
+
+create index IX_covered_text on anno_token(coveredText);
+create index IX_canonical_form on anno_token(canonicalForm);
+
+create table anno_date (
+	anno_base_id int not null,
+	tstamp timestamp,
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE 
+) ;
+
+create table anno_markable (
+	anno_base_id int not null,
+	id int default 0,
+	anaphoric_prob double PRECISION default 0,
+	content int default 0,
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE 
+);
+
+create table anno_treebank_node (
+	anno_base_id int not null,
+	parent int default 0,
+	nodeType varchar2(10),
+	nodeValue varchar2(10),
+	leaf numeric(1) default 0,
+	headIndex int default 0,
+	"index" int default 0,
+	tokenIndex int default 0,
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE 
+);
+
+create table anno_link (
+	anno_link_id int not null,
+	parent_anno_base_id int not null,
+	child_anno_base_id int not null,
+	feature varchar2(20),
+	primary key (anno_link_id),
+	foreign key (parent_anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE 
+);
+create index IX_link on anno_link(parent_anno_base_id, child_anno_base_id, feature);
+
+create table anno_contain (
+  parent_anno_base_id int not null,
+  parent_uima_type_id int not null,
+  child_anno_base_id int not null,
+  child_uima_type_id int not null,
+  primary key (parent_anno_base_id, child_anno_base_id),
+  foreign key (parent_anno_base_id)
+		references anno_base(anno_base_id)
+		ON DELETE CASCADE
+);
+
+CREATE INDEX IX_anno_contain_p ON anno_contain (parent_anno_base_id, child_uima_type_id)
+;
+
+CREATE INDEX IX_anno_contain_c ON anno_contain (child_anno_base_id, parent_uima_type_id)
+;
+
+
+CREATE TABLE fracture_demo (
+	note_id int NOT NULL primary key,
+	site_id varchar2(10) NULL,
+	note_text clob NULL,
+	fracture varchar2(20) NULL,
+	note_set varchar2(10) NULL
+);
+
+
+-- metamap tables
+create table anno_mm_candidate (
+	anno_base_id int not null,
+	cui char(8),
+	score int default 0,
+	head numeric(1) default 0,
+	overmatch numeric(1) default 0,
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE
+);
+
+create table anno_mm_acronym (
+	anno_base_id int not null,
+	acronym varchar2(10),
+    "expansion" varchar2(30),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE
+);
+
+create table anno_mm_utterance (
+	anno_base_id int not null,
+	pmid varchar2(10),
+    location varchar2(30),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE
+);
+
+
+create table anno_mm_cuiconcept (
+    anno_mm_cuiconcept_id int not null,
+    anno_base_id int,
+    negExCui char(8),
+	primary key (anno_mm_cuiconcept_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE
+);
+
+create table anno_mm_negation (
+    anno_base_id int not null,
+    negType varchar2(10),
+    negTrigger varchar2(10),
+	primary key (anno_base_id),
+	foreign key (anno_base_id) references anno_base(anno_base_id) ON DELETE CASCADE
+);
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document_trg.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document_trg.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document_trg.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_document_trg.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,32 @@
+-- insert triggers to generate primary keys from sequence
+create or replace trigger trg_anno_ontology_concept before insert on anno_ontology_concept
+for each row
+when (new.anno_ontology_concept_id is null)
+begin
+ select anno_onto_concept_id_sequence.nextval into :new.anno_ontology_concept_id from dual;
+end;
+/
+
+create or replace trigger trg_anno_link before insert on anno_link
+for each row
+when (new.anno_link_id is null)
+begin
+ select anno_link_id_sequence.nextval into :new.anno_link_id from dual;
+end;
+/
+
+create or replace trigger trg_fracture_demo before insert on fracture_demo
+for each row
+when (new.note_id is null)
+begin
+ select demo_note_id_sequence.nextval into :new.note_id from dual;
+end;
+/
+
+create or replace trigger trg_anno_mm_cuiconcept before insert on anno_mm_cuiconcept
+for each row
+when (new.anno_mm_cuiconcept_id is null)
+begin
+ select anno_mm_cuiconcept_id_sequence.nextval into :new.anno_mm_cuiconcept_id from dual;
+end;
+/

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,61 @@
+create sequence named_entity_regex_id_sequence;
+create sequence segment_regex_id_sequence;
+create sequence hibernate_sequence;
+
+create table hibernate_sequences (
+	sequence_name varchar2(100) not null,
+	next_val int default 1 not null,
+	primary key (sequence_name)
+);
+insert into hibernate_sequences(sequence_name, next_val) values ('document_id_sequence', 1);
+
+create table anno_base_sequence (
+	sequence_name varchar(100) not null,
+	next_val int not null default 1,
+	primary key (sequence_name)
+);
+insert into anno_base_sequence(sequence_name, next_val) values ('anno_base_id_sequence', 1);
+
+
+create table ref_named_entity_regex (
+	named_entity_regex_id int NOT NULL,
+	regex varchar2(512) not null,
+	coding_scheme varchar2(20) not null,
+	code varchar2(20) not null,
+	oid varchar2(10) null,
+	context varchar2(256) null,
+	primary key (named_entity_regex_id)
+) ;
+
+create table ref_segment_regex (
+	segment_regex_id int  NOT NULL,
+	regex varchar2(256) not null,
+	segment_id varchar2(256) not null,
+	limit_to_regex numeric(1) default 0 check (limit_to_regex between 0 and 1),
+	primary key (segment_regex_id)
+) ;
+
+create table ref_uima_type (
+	uima_type_id int not null,
+	uima_type_name varchar2(256) not null,
+	table_name varchar(100) null,
+	CONSTRAINT PK_ref_uima_type PRIMARY KEY  
+	(
+		uima_type_id 
+	)
+) ;
+
+CREATE UNIQUE  INDEX NK_ref_uima_type ON ref_uima_type
+(
+	uima_type_name
+)
+;
+
+CREATE TABLE ref_stopword (
+	stopword varchar(50) not null,
+	constraint PK_ref_stopword primary key
+	(
+		stopword
+	)
+)
+;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference_trg.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference_trg.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference_trg.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_reference_trg.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,17 @@
+-- insert triggers to generate primary keys from sequence
+
+create or replace trigger trg_ref_named_entity_regex before insert on ref_named_entity_regex
+for each row
+when (new.named_entity_regex_id is null)
+begin
+ select named_entity_regex_id_sequence.nextval into :new.named_entity_regex_id from dual;
+end;
+/
+
+create or replace trigger trg_ref_segment_regex before insert on ref_segment_regex
+for each row
+when (new.segment_regex_id is null)
+begin
+ select segment_regex_id_sequence.nextval into :new.segment_regex_id from dual;
+end;
+/
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/create_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,55 @@
+create view v_document as
+-- We assume the metadata about documents (patient id, date) come from
+-- some table in your database.  modify this view to join with that table
+-- and get this info
+select analysis_batch, document_id, doc_text, instance_id, null patient_id, null doc_date, null doc_title, null document_type_name
+from document;
+;
+
+create view v_annotation
+AS
+SELECT anno.*, ur.uima_type_name, substr(doc.doc_text, anno.span_begin+1, anno.span_end-anno.span_begin) anno_text, doc.analysis_batch
+FROM anno_base  anno 
+INNER JOIN v_document doc ON doc.document_id = anno.document_id
+INNER JOIN REF_UIMA_TYPE  ur on ur.uima_type_id = anno.uima_type_id
+;
+
+create view v_document_cui_sent
+as
+-- this view gives the document info, cui info, and sentence info in which a cui is found
+SELECT 
+  da.anno_base_id,
+  d.analysis_batch,
+  da.document_id, 
+  ne.polarity, 
+  o.code, 
+  substr(d.doc_text, da.span_begin+1, da.span_end-da.span_begin) cui_text, 
+  substr(d.doc_text, s.span_begin+1, s.span_end-s.span_begin) sentence_text,
+  o.disambiguated,
+  d.patient_id,
+  d.doc_date,
+  d.doc_title,
+  d.document_type_name
+FROM anno_base da 
+INNER JOIN anno_named_entity  ne ON da.anno_base_id = ne.anno_base_id 
+INNER JOIN anno_ontology_concept  o ON o.anno_base_id = ne.anno_base_id 
+left join 
+( 
+  --  get the sentence that contains the cui
+  select ac.child_anno_base_id, s.span_begin, s.span_end
+  from anno_contain ac 
+  INNER join anno_base s on ac.parent_anno_base_id = s.anno_base_id
+  where s.uima_type_id in (select uima_type_id from ref_uima_type where uima_type_name = 'edu.mayo.bmi.uima.core.type.textspan.Sentence')
+  and ac.child_uima_type_id in (select uima_type_id from ref_uima_type where uima_type_name = 'edu.mayo.bmi.uima.core.type.textsem.EntityMention')
+) s on da.anno_base_id = s.child_anno_base_id
+INNER JOIN v_document d on da.document_id = d.document_id
+;
+
+CREATE VIEW v_document_ontoanno
+AS
+SELECT d.document_id, da.span_begin, da.span_end, ne.polarity, o.code, d.analysis_batch, substr(d.doc_text, da.span_begin+1, da.span_end-da.span_begin) cui_text, da.anno_base_id, o.disambiguated, o.cui 
+FROM v_document d INNER JOIN
+anno_base  da ON d.document_id = da.document_id INNER JOIN
+anno_named_entity  ne ON da.anno_base_id = ne.anno_base_id INNER JOIN
+anno_ontology_concept  o ON o.anno_base_id = ne.anno_base_id
+;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_document.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_document.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_document.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_document.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,57 @@
+drop trigger trg_anno_mm_cuiconcept;
+drop trigger trg_fracture_demo;
+drop trigger trg_anno_link;
+drop trigger trg_anno_ontology_concept;
+
+-- legacy
+drop sequence document_id_sequence;
+drop sequence anno_base_id_sequence;
+-- end legacy
+drop sequence anno_onto_concept_id_sequence;
+drop sequence anno_link_id_sequence;
+drop sequence anno_contain_id_sequence;
+drop sequence demo_note_id_sequence;
+drop sequence anno_mm_cuiconcept_id_sequence;
+
+
+drop index IX_anno_contain_c;
+drop index IX_anno_contain_p;
+drop index IX_ontology_concept_code;
+drop index IX_umls_concept_cui;
+drop index IX_instance_id;
+drop index IX_instance_key;
+drop index IX_document_analysis_batch;
+drop INDEX IX_docanno_doc;
+drop INDEX IX_covered_text;
+drop index IX_segment_anno_seg;
+drop index IX_link;
+
+-- drop 'operational' data
+drop table fracture_demo;
+drop table anno_contain;
+drop table anno_link;
+-- legacy
+drop table anno_source_doc_info;
+drop table anno_num_token;
+drop table anno_word_token;
+drop table anno_base_token;
+drop table anno_umls_concept;
+drop table anno_segment;
+-- end legacy
+drop table anno_mm_cuiconcept;
+drop table anno_mm_candidate;
+drop table anno_mm_acronym;
+drop table anno_mm_utterance;
+drop table anno_mm_negation;
+drop table anno_token;
+drop table anno_markable;
+drop table anno_treebank_node;
+drop table anno_drug_mention;
+drop table anno_ontology_concept;
+drop table anno_named_entity;
+drop table anno_med_event;
+drop table anno_sentence;
+drop table anno_date;
+drop table anno_base;
+drop table document;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_reference.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_reference.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_reference.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_reference.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,15 @@
+drop trigger trg_ref_named_entity_regex; 
+drop trigger trg_ref_segment_regex; 
+
+drop sequence named_entity_regex_id_sequence;
+drop sequence segment_regex_id_sequence;
+drop sequence hibernate_sequence;
+
+drop index NK_ref_uima_type;
+-- drop 'reference' data
+drop table ref_uima_type;
+drop table ref_named_entity_regex;
+drop table ref_segment_regex;
+drop table ref_stopword;
+drop table hibernate_sequences;
+drop table anno_base_sequence;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/drop_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,4 @@
+drop view V_ANNOTATION;
+drop VIEW V_DOCUMENT_ONTOANNO;
+drop view v_document;
+drop view v_document_cui_sent;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/fracture_demo.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/fracture_demo.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/fracture_demo.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/uima/fracture_demo.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1 @@
+update fracture_demo set note_text = replace(note_text, '<br/>', CHR(10));

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_indices.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_indices.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_indices.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_indices.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,2 @@
+create index IX_fword on umls_aui_fword (fword);
+create index IX_fstem on umls_aui_fword (fstem);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,8 @@
+create table umls_aui_fword (
+	aui varchar2(9) not null primary key,
+	fword varchar2(100) not null,
+	fstem varchar2(100) null,
+	tok_str varchar2(250) not null,
+	stem_str varchar2(250) null
+);
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,37 @@
+create table v_snomed_fword_lookup
+as
+select mrc.cui, t.tui, c.fword, c.fstem, c.tok_str, c.stem_str
+from umls_aui_fword c
+inner join ytex.MRCONSO mrc on c.aui = mrc.aui and mrc.SAB in ( 'SNOMEDCT', 'RXNORM')
+inner join 
+(
+	select cui, min(tui) tui
+	from ytex.MRSTY sty
+	where sty.tui in
+	(
+    /* diseasesAndDisordersTuis */
+    'T019', 'T020', 'T037', 'T046', 'T047', 'T048', 'T049', 'T050', 
+      'T190', 'T191', 'T033',
+    /* signAndSymptomTuis */
+    'T184',
+    /* anatomicalSitesTuis */
+    'T017', 'T029', 'T023', 'T030', 'T031', 'T022', 'T025', 'T026',
+        'T018', 'T021', 'T024',
+    /* medicationsAndDrugsTuis */
+     'T116', 'T195', 'T123', 'T122', 'T118', 'T103', 'T120', 'T104',
+        'T200', 'T111', 'T196', 'T126', 'T131', 'T125', 'T129', 'T130',
+        'T197', 'T119', 'T124', 'T114', 'T109', 'T115', 'T121', 'T192',
+        'T110', 'T127',
+	/* proceduresTuis */
+    'T060', 'T065', 'T058', 'T059', 'T063', 'T062', 'T061',
+    /* deviceTuis */
+    'T074', 'T075',
+    /* laboratoryTuis */
+    'T059'
+	)
+	group by cui
+) t on t.cui = mrc.cui
+;
+create index IX_vsnfl_cui on v_snomed_fword_lookup(cui);
+create index IX_vsnfl_fword on v_snomed_fword_lookup(fword);
+create index IX_vsnfl_fstem on v_snomed_fword_lookup(fstem);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.template.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.template.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.template.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/create_view.template.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,37 @@
+create table v_snomed_fword_lookup
+as
+select mrc.cui, t.tui, c.fword, c.fstem, c.tok_str, c.stem_str
+from umls_aui_fword c
+inner join @UMLS_SCHEMA@.MRCONSO mrc on c.aui = mrc.aui and mrc.SAB in ( 'SNOMEDCT', 'RXNORM')
+inner join 
+(
+	select cui, min(tui) tui
+	from @UMLS_SCHEMA@.MRSTY sty
+	where sty.tui in
+	(
+    /* diseasesAndDisordersTuis */
+    'T019', 'T020', 'T037', 'T046', 'T047', 'T048', 'T049', 'T050', 
+      'T190', 'T191', 'T033',
+    /* signAndSymptomTuis */
+    'T184',
+    /* anatomicalSitesTuis */
+    'T017', 'T029', 'T023', 'T030', 'T031', 'T022', 'T025', 'T026',
+        'T018', 'T021', 'T024',
+    /* medicationsAndDrugsTuis */
+     'T116', 'T195', 'T123', 'T122', 'T118', 'T103', 'T120', 'T104',
+        'T200', 'T111', 'T196', 'T126', 'T131', 'T125', 'T129', 'T130',
+        'T197', 'T119', 'T124', 'T114', 'T109', 'T115', 'T121', 'T192',
+        'T110', 'T127',
+	/* proceduresTuis */
+    'T060', 'T065', 'T058', 'T059', 'T063', 'T062', 'T061',
+    /* deviceTuis */
+    'T074', 'T075',
+    /* laboratoryTuis */
+    'T059'
+	)
+	group by cui
+) t on t.cui = mrc.cui
+;
+create index IX_vsnfl_cui on v_snomed_fword_lookup(cui);
+create index IX_vsnfl_fword on v_snomed_fword_lookup(fword);
+create index IX_vsnfl_fstem on v_snomed_fword_lookup(fstem);

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_tables.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_tables.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_tables.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_tables.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,4 @@
+drop index IX_fword;
+drop index IX_fstem;
+DROP TABLE umls_aui_fword;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_view.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_view.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_view.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/drop_view.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,6 @@
+drop index IX_vsnfl_cui;
+drop index IX_vsnfl_fword;
+drop index IX_vsnfl_fstem;
+drop view v_snomed_fword_lookup;
+drop table v_snomed_fword_lookup;
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/import_umls.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/import_umls.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/import_umls.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/import_umls.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,31 @@
+CREATE TABLE MRCONSO (
+    CUI	char(8) NOT NULL,
+    LAT	char(3) NOT NULL,
+    TS	char(1) NOT NULL,
+    LUI	varchar2(10) NOT NULL,
+    STT	varchar2(3) NOT NULL,
+    SUI	varchar2(10) NOT NULL,
+    ISPREF	char(1) NOT NULL,
+    AUI	varchar2(9) NOT NULL primary key,
+    SAUI	varchar2(50),
+    SCUI	varchar2(50),
+    SDUI	varchar2(50),
+    SAB	varchar2(20) NOT NULL,
+    TTY	varchar2(20) NOT NULL,
+    CODE	varchar2(50) NOT NULL,
+    STR	varchar2(3000) NOT NULL,
+    SRL	int NOT NULL,
+    SUPPRESS	char(1) NOT NULL,
+    CVF	int
+) ;
+
+
+CREATE TABLE MRSTY (
+    CUI	char(8) NOT NULL,
+    TUI	char(4) NOT NULL,
+    STN	varchar2(100) NOT NULL,
+    STY	varchar2(50) NOT NULL,
+    ATUI varchar2(11) NOT NULL,
+    CVF	int 
+);
+

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/index_umls.sql
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/index_umls.sql?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/index_umls.sql (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/orcl/umls/index_umls.sql Mon Dec 16 16:30:30 2013
@@ -0,0 +1,23 @@
+CREATE INDEX X_MRCONSO_CUI ON MRCONSO(CUI)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRCONSO_SUI ON MRCONSO(SUI)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRCONSO_LUI ON MRCONSO(LUI)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRCONSO_CODE ON MRCONSO(CODE)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRCONSO_SAB_TTY ON MRCONSO(SAB,TTY)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRSTY_CUI ON MRSTY(CUI)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRSTY_STY ON MRSTY(STY)
+PCTFREE 10 COMPUTE STATISTICS;
+
+CREATE INDEX X_MRSTY_CUITUI ON MRSTY(CUI, TUI)
+PCTFREE 10 COMPUTE STATISTICS;

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.txt
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.txt?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.txt (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.txt Mon Dec 16 16:30:30 2013
@@ -0,0 +1,38 @@
+1	org.apache.ctakes.typesystem.type.textsem.DateAnnotation	
+2	org.apache.ctakes.typesystem.type.textsem.FractionAnnotation	
+3	org.apache.ctakes.typesystem.type.textsem.MeasurementAnnotation	
+4	org.apache.ctakes.typesystem.type.textsem.PersonTitleAnnotation	
+5	org.apache.ctakes.typesystem.type.textsem.RangeAnnotation	
+6	org.apache.ctakes.typesystem.type.textsem.RomanNumeralAnnotation	
+7	org.apache.ctakes.typesystem.type.textsem.TimeAnnotation	
+8	org.apache.ctakes.typesystem.type.textsem.EntityMention	anno_named_entity
+9	org.apache.ctakes.typesystem.type.textspan.Sentence	anno_sentence
+12	org.apache.ctakes.typesystem.type.textspan.Segment	anno_segment	
+20	org.apache.ctakes.typesystem.type.syntax.ContractionToken	
+21	org.apache.ctakes.typesystem.type.syntax.NewlineToken	
+22	org.apache.ctakes.typesystem.type.syntax.NumToken	anno_token
+23	org.apache.ctakes.typesystem.type.syntax.PunctuationToken	
+24	org.apache.ctakes.typesystem.type.syntax.SymbolToken	
+25	org.apache.ctakes.typesystem.type.syntax.WordToken	anno_token
+27	org.apache.ctakes.typesystem.type.syntax.NP	
+28	org.apache.ctakes.typesystem.type.syntax.VP	
+29	org.apache.ctakes.typesystem.type.refsem.OntologyConcept	anno_ontology_concept
+30	org.apache.ctakes.ytex.uima.types.OntologyConcept	anno_ontology_concept
+31	org.apache.ctakes.typesystem.type.refsem.UmlsConcept	anno_ontology_concept
+32	org.apache.ctakes.typesystem.type.textsem.MedicationEventMention	anno_med_event
+33	org.apache.ctakes.coreference.type.Markable	anno_markable	
+34	org.apache.ctakes.coreference.type.DemMarkable	anno_markable	
+35	org.apache.ctakes.coreference.type.NEMarkable	anno_markable	
+36	org.apache.ctakes.coreference.type.PronounMarkable	anno_markable	
+40	org.apache.ctakes.typesystem.type.syntax.TreebankNode	anno_treebank_node
+41	org.apache.ctakes.typesystem.type.syntax.TopTreebankNode	anno_treebank_node	
+42	org.apache.ctakes.typesystem.type.syntax.TerminalTreebankNode	anno_treebank_node	
+50	org.apache.ctakes.ytex.uima.types.Date	
+100	gov.nih.nlm.nls.metamap.uima.ts.Document	
+101	org.metamap.uima.ts.Phrase	
+102	org.metamap.uima.ts.Candidate	anno_mm_candidate
+103	gov.nih.nlm.nls.metamap.uima.ts.AcronymAbbrev	anno_mm_acronym
+104	org.metamap.uima.ts.Utterance	anno_mm_utterance
+105	org.metamap.uima.ts.CuiConcept	anno_mm_cuiconcept
+106	org.metamap.uima.ts.Span	
+107	org.metamap.uima.ts.Negation	anno_mm_negation

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/ref_uima_type.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,9 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="@db.schema@.ref_uima_type" commit="10000" delimiter="&#009;">
+		<column name="uima_type_id" />
+		<column name="uima_type_name" />
+		<column name="table_name" />
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_concept.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_concept.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_concept.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_concept.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="sct2_concept" commit="10000" delimiter="&#009;" skip="1">
+		<column name="id"/>
+		<column name="effectiveTime" format="java.text.SimpleDateFormat" pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#"/>
+		<column name="moduleId"/>
+		<column name="definitionStatusId"/>
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_description.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_description.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_description.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_description.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<!-- tiny hack - encapsulator defaults to " and can't be set to null. some 
+		snomed strings have quotes which throws off the csv parser. tilde doesn't 
+		appear anywhere so safe to use this as encapsulator -->
+	<csv table="sct2_description" commit="10000" delimiter="&#009;"
+		skip="1" encapsulator="~">
+		<column name="id" />
+		<column name="effectiveTime" format="java.text.SimpleDateFormat"
+			pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#" />
+		<column name="moduleId" />
+		<column name="conceptId" />
+		<column name="languageCode" />
+		<column name="typeId" />
+		<column name="term" />
+		<column name="caseSignificanceId" />
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_relationship.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_relationship.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_relationship.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2_relationship.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="sct2_relationship" commit="10000" delimiter="&#009;" skip="1">
+		<column name="id"/>
+		<column name="effectiveTime" format="java.text.SimpleDateFormat" pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#"/>
+		<column name="moduleId"/>
+		<column name="sourceId"/>
+		<column name="destinationId"/>
+		<column name="relationshipGroup"/>
+		<column name="typeId"/>
+		<column name="characteristicTypeId"/>
+		<column name="modifierId"/>
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_concept.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_concept.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_concept.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_concept.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,11 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="sct2f_concept" commit="10000" delimiter="&#009;" skip="1">
+		<column name="id"/>
+		<column name="effectiveTime" format="java.text.SimpleDateFormat" pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#"/>
+		<column name="moduleId"/>
+		<column name="definitionStatusId"/>
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_description.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_description.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_description.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_description.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,20 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<!-- tiny hack - encapsulator defaults to " and can't be set to null. some 
+		snomed strings have quotes which throws off the csv parser. tilde doesn't 
+		appear anywhere so safe to use this as encapsulator -->
+	<csv table="sct2f_description" commit="10000" delimiter="&#009;"
+		skip="1" encapsulator="~">
+		<column name="id" />
+		<column name="effectiveTime" format="java.text.SimpleDateFormat"
+			pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#" />
+		<column name="moduleId" />
+		<column name="conceptId" />
+		<column name="languageCode" />
+		<column name="typeId" />
+		<column name="term" />
+		<column name="caseSignificanceId" />
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_relationship.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_relationship.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_relationship.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/snomedct/sct2f_relationship.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,16 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="sct2f_relationship" commit="10000" delimiter="&#009;" skip="1">
+		<column name="id"/>
+		<column name="effectiveTime" format="java.text.SimpleDateFormat" pattern="yyyyMMdd" />
+		<column name="active" format="java.text.DecimalFormat" pattern="#"/>
+		<column name="moduleId"/>
+		<column name="sourceId"/>
+		<column name="destinationId"/>
+		<column name="relationshipGroup"/>
+		<column name="typeId"/>
+		<column name="characteristicTypeId"/>
+		<column name="modifierId"/>
+	</csv>
+</load>
\ No newline at end of file

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.txt
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.txt?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.txt (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.txt Mon Dec 16 16:30:30 2013
@@ -0,0 +1,360 @@
+a
+about
+according
+across
+actually
+adj
+after
+afterwards
+against
+all
+almost
+alone
+along
+already
+also
+although
+always
+among
+amongst
+an
+and
+another
+any
+anyhow
+anyone
+anything
+anywhere
+are
+aren't
+around
+as
+at
+b
+be
+became
+because
+become
+becomes
+becoming
+been
+before
+beforehand
+begin
+beginning
+behind
+being
+beside
+besides
+between
+beyond
+billion
+but
+by
+c
+can
+can't
+cannot
+caption
+co
+co.
+could
+couldn't
+d
+did
+didn't
+do
+does
+doesn't
+don't
+down
+during
+e
+each
+eg
+eight
+eighty
+either
+else
+elsewhere
+etc
+even
+ever
+every
+everyone
+everything
+everywhere
+f
+fifty
+first
+five
+for
+former
+formerly
+forty
+found
+four
+from
+further
+g
+h
+had
+has
+hasn't
+have
+haven't
+he
+he'd
+he'll
+he's
+hence
+her
+here
+here's
+hereafter
+hereby
+herein
+hereupon
+hers
+herself
+him
+himself
+his
+how
+however
+hundred
+i
+i'd
+i'll
+i'm
+i've
+ie
+if
+in
+inc.
+indeed
+instead
+into
+is
+isn't
+it
+it's
+its
+itself
+j
+k
+l
+let
+let's
+like
+likely
+ltd
+m
+made
+make
+makes
+many
+maybe
+me
+meantime
+meanwhile
+might
+million
+miss
+moreover
+mr
+mrs
+much
+must
+my
+myself
+n
+namely
+nevertheless
+next
+nine
+ninety
+nobody
+none
+nonetheless
+noone
+nor
+nothing
+now
+nowhere
+o
+of
+off
+often
+on
+once
+one
+one's
+only
+onto
+or
+other
+others
+otherwise
+our
+ours
+ourselves
+out
+over
+overall
+own
+p
+per
+perhaps
+q
+r
+rather
+recent
+recently
+s
+same
+seem
+seemed
+seeming
+seems
+seven
+seventy
+several
+she
+she'd
+she'll
+she's
+should
+shouldn't
+since
+six
+sixty
+so
+some
+somehow
+someone
+something
+sometime
+sometimes
+somewhere
+still
+stop
+such
+t
+taking
+ten
+than
+that
+that'll
+that's
+that've
+the
+their
+them
+themselves
+then
+thence
+there
+there'd
+there'll
+there're
+there's
+there've
+thereafter
+thereby
+therefore
+therein
+thereupon
+these
+they
+they'd
+they'll
+they're
+they've
+thirty
+this
+those
+though
+thousand
+three
+through
+throughout
+thru
+thus
+to
+together
+too
+toward
+towards
+trillion
+twenty
+two
+u
+until
+up
+upon
+us
+used
+using
+v
+very
+via
+w
+was
+wasn't
+we
+we'd
+we'll
+we're
+we've
+well
+were
+weren't
+what
+what'll
+what's
+what've
+whatever
+when
+whence
+whenever
+where
+where's
+whereafter
+whereas
+whereby
+wherein
+whereupon
+wherever
+whether
+which
+while
+whither
+who
+who'd
+who'll
+who's
+whoever
+whole
+whom
+whomever
+whose
+why
+will
+won't
+would
+wouldn't
+x
+y
+yes
+yet
+you
+you'd
+you'll
+you're
+you've
+your
+yours
+yourself
+yourselves
+z

Added: ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.xml
URL: http://svn.apache.org/viewvc/ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.xml?rev=1551254&view=auto
==============================================================================
--- ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.xml (added)
+++ ctakes/branches/ytex/ctakes-ytex/scripts/data/stopword.xml Mon Dec 16 16:30:30 2013
@@ -0,0 +1,7 @@
+<?xml version="1.0" encoding="utf-8"?>
+<load xmlns:xsi="http://www.w3.org/2001/XMLSchema-instance"
+	xsi:schemaLocation="http://jdl-prj.googlecode.com/files/xdl.xsd">
+	<csv table="@db.schema@.ref_stopword" commit="10000">
+		<column name="stopword" />
+	</csv>
+</load>
\ No newline at end of file



Mime
View raw message