Using the below XML example, what's the best way to write the Xpath3 expression
If fruit is apple and quantity is less than 12 or if fruit is watermelon and quantity is less than 2) then return "in-store shopping" otherwise "online"`
<table>
<fruit>Apple</fruit>
<quantity>5</quantity>
</table>
I tried below but it didn't work. I got an error saying "Error: Expected 'then' token in conditional if expression"
if(//fruit= "apple" and //quantity<12) or if(//fruit= "watermelon" and //quantity<2)
then "in-store shopping" else "online"