Next in thread → Next in month →

RE: [xml-dev] Questions on XQuery operators

From
Michael Kay <>
To
'Shaorong Liu' <>,
Date
2004-03-18T22:24:26
ID
<20040318222352.RMGC5865.mta03-svc.ntlworld.com@Turtle>
Thread
RE: [xml-dev] Questions on XQuery operators
# 
#   I am wondering whether XQuery supports the "IN" operator as 
# SQL. For example, is the following XQuery (find a person with 
# age 20, 25 or 30)
# valid:
# 
#    for $p in input()//person
#    where $p/age in (20, 25, 30)
#    return $p
# 
The "=" operator does this (as in XPath)

#    for $p in input()//person
#    where $p/age = (20, 25, 30)
#    return $p

Michael Kay
Next in thread → Next in month →