xQuery Statement Modification
$30-100 USD
Paid on delivery
I have a attached an xQuery statement that takes an XML document and generates a row for each section in the XML document.? I now need to modify this query to look for specific sections from the document.? In other words, instead of returning all sections, only return the sections that have a specific section code or section title.
So I need a filter that will do the following.? Select all sections from? the JobSample table that have JobXML that contains code=5010 or? if the code=0 then return the sections that have a title of Current Medications or a title of Medications or a title of Current Meds.
(here's? a sample section that contains a code=5010? - the entire XML document is attached and is in the backup data base).
? <component>
? <section>
? <title>Current Medications</title>
? <code code="5010" codeSystem="2.16.840.1.113883.3.21" codeSystemName="MM-LOINC" />
? <text>
? <paragraph>
? <content ID="concept_2">Zoloft</content>
? <content>.</content>
? </paragraph>
? </text>
? <entry>
? <entryChoice>
? ? <Observation>
? <code code="5009" codeSystem="2.16.840.1.113883.3.21" codeSystemName="MM-LOINC" displayName="medication" />?
? ? <value>
? <mm:conceptProperty mm:name="med" mm:value="Zoloft" />
? <mm:conceptProperty mm:name="drug" mm:value="Zoloft" />
? <mm:conceptProperty mm:name="dose" mm:value="" />
? <originalText>
? <reference value="#concept_2" />
? </originalText>
? </value>
? </Observation>
? </entryChoice>
? </entry>
? </section>
? </component>
The sample data base has 3 records - 2 have a code=5010 and 1 record has a code=0 and a title of Current Medications.
Project ID: #3710613