Is there a way to do a short circuited or operator in XQuery like you can do in C#, Java, JavaScript, etc?
I have some XML that can be in two formats, either:
<sometag>
<bodytext>
<section>
<bodytext>
<h1>Some html here</h1>
<h2>Some more html</h2>
</bodytext>
</section>
</bodytext>
</sometag>
or
<sometag>
<bodytext>
<h1>Some html here</h1>
<h2>Some more html</h2>
</bodytext>
</sometag>
I'm trying to return the html that's inside the inner body text tag. If i do
/sometag/bodytext/section/bodytext/*
will return the first scenario
/sometag/bodytext/*
it will return the second scenario.