XQuery and the AND operator

I have the following query:
http://localhost/tamino/xml/sailing?_xql=cruiseCatalog/cruise[route/date[1]>=20010701 and route/date[last()]<=20010731]/route
I should get all the cruise data that starts and ends in the month of July, but for some reason the “and” operator does not seem to take effect.
I use and the date element is an integer with stardard search

It is strange because I use the same version but receive accurate results for queries like that.

Are you sure that you were not mistaken in your query? If you have many routes for a cruise and one date element for each route, the query should be different a little:

http://localhost/tamino/xml/sailing?_xql=cruiseCatalog/cruise[route[1]/date>=20010701 and route[last()]/date<=20010731]/route

It is just a guess because I do not know your schema.