Unanswered: Oracle9i XMLType column query with different response time
I executed the queries below on an oracle9i xmltype column with over 122K records. Searching for a value that is in the database results much faster than non existing value.
Query1: elapsed time 250 milliseconds
from repository e
and e.xmlTypecol,extract('/metadata/beginning_date/year/text()').getNumberVal() > 2000;
Query2: elapsed time 18 minutes
same as above except "getNumberVal() > 2005" which is not in the database.
Since both queries use the method of searching, I don't understand why the first query is faster than the second query which is taking an unreasonable amount of time.