
org.apache.ctakes.ytex.web.search.mysql.properties Maven / Gradle / Ivy
The newest version!
#
# Licensed to the Apache Software Foundation (ASF) under one
# or more contributor license agreements. See the NOTICE file
# distributed with this work for additional information
# regarding copyright ownership. The ASF licenses this file
# to you under the Apache License, Version 2.0 (the
# "License"); you may not use this file except in compliance
# with the License. You may obtain a copy of the License at
#
# http://www.apache.org/licenses/LICENSE-2.0
#
# Unless required by applicable law or agreed to in writing,
# software distributed under the License is distributed on an
# "AS IS" BASIS, WITHOUT WARRANTIES OR CONDITIONS OF ANY
# KIND, either express or implied. See the License for the
# specific language governing permissions and limitations
# under the License.
#
retrieveConceptByFword=\
select distinct fword, cui conceptId, SUBSTRING(tok_str, 1, 30) text \
from v_snomed_fword_lookup \
where fword = :fword \
and substring(tok_str, 1, :termlen) = :term \
order by tok_str \
limit 30
# used by DocumentSearchDao
retrieveDocumentByCUI=\
select distinct document_id, \
cast(cui_text as char(256)) cui_text, \
cast(sentence_text as char(256)) sentence_text, \
patient_id, \
doc_date, \
cast(doc_title as char(256)) doc_title, \
document_type_name \
from v_document_cui_sent \
where code = :code \
and (:certainty is null or polarity = :certainty) \
and (:patient_id is null or patient_id = :patient_id) \
and (:from_doc_date is null or doc_date >= :from_doc_date) \
and (:to_doc_date is null or doc_date <= :to_doc_date) \
and (:document_type_name is null or document_type_name = :document_type_name) \
limit 100
# map concept id to preferred term for concept id
# try to get preferred term; if there isn't one, get the 'first' string
retrieveTermByConceptId=\
select coalesce(s2.term, s1.term) term \
from \
( \
select min(str) term \
from @[email protected] \
where cui = :conceptId \
and lat = 'ENG' \
) s1 \
, \
( \
select min(str) term \
from @[email protected] \
where tty in ('PT', 'PN') \
and cui = :conceptId \
and lat = 'ENG' \
) s2
retrieveDocumentByID=select doc_text from v_document where document_id = ?
© 2015 - 2025 Weber Informatics LLC | Privacy Policy