This content has been marked as final. Show 4 replies
Oops! Did it wrong...
Only realized just now that I gave those examples the wrongway. They should be, according to the [url http://docs.oracle.com/cd/E11882_01/appdev.112/e11830/sdo_operat.htm#i78531] documentation :
select /*+ ORDERED */ a.idnumber from poly2 b, poly1 a where NOT sdo_relate(a.geometry, b.geometry, 'mask=TOUCH')='TRUE';
Documentation says:If two or more geometries from geometry2 are passed to the operator, the ORDERED optimizer hint must be specified, and the table in geometry2 must be specified first in the FROM clause.This should improve your performance. Just make sure both SDO_GEOMETRY columns have proper Spatial Indexes.