Skip to Main Content

Integration

Announcement

For appeals, questions and feedback about Oracle Forums, please email oracle-forums-moderators_us@oracle.com. Technical questions should be asked in the appropriate category. Thank you!

How to check if a node tag AND a node value exist?

pstein-JavaNetSep 24 2010 — edited Feb 27 2020
In a switch condition I want to check if a certain xml node (e.g. <aaa/> exists and if that xml node
contains a value not equal to whitespace(s) (e.g.<aaa>myvalue123<aaa/>). I code the following expression:

boolean(bpws:getVariableData('.......','...','/ns4:aaa')) and
xp20:compare(normalize-space(bpws:getVariableData('.......','...','/ns4:aaa')),'') != 0

Is this working?

Is there a better/smarter/shorter way to check this?

Peter
Comments
Locked Post
New comments cannot be posted to this locked post.
Post Details
Locked on Oct 22 2010
Added on Sep 24 2010
1 comment
810 views