Hi,
I am using Oracle Spatial context to detect if an object enters in a specific area.
I actually compare one by one position with geoms (from a wlevs:cache) with a list of geoms active for that user
with a condition like this cacheGeoms.idGeom = ceob.geom.idGeom.
But my goal is to know if an object enters any of these geometries, without doing one by one, but in this case I get
Invalid statement: "alter query >>QueryGoOutBuffer<< start"
Description: specified predicate requires full scan of external source which is not supported
In Oracle spatial SQL, we can use sdo_contains (geom, mymovingpoint)='TRUE', and it uses the index on geom to get all interacting geometries).
Why is it not working like this using the cache.
What should I use to make this working ?
Here is sample of the query:
select distinct
ceob.iosDeviceDataEvent as iOSDeviceDataEvent,
ceob.aboService as aboService,
ceob.service as service,
ceob.device as device,
ceob.deviceParam as deviceParam,
ceob.eventsConfig as eventsConfig,
com.oscars.giplibrary.core.eventtypes.dbmapping.Geom(cacheGeoms.idGeom, cacheGeoms.geomName) as geom,
ceob.notification as notification,
ceob.recipient as recipient,
ceob.recipientsNotification as recipientsNotification,
ceob.user as user,
ceob.place as place,
ceob.device.nameDevice as nameDevice,
cacheGeoms.geomName as geomName,
ceob.eventsConfig.eventTrigger as eventTrigger,
(case when CONTAIN@GIPCoreCtx(cacheGeoms.geom, com.oracle.cep.cartridge.spatial.Geometry.createPoint@GIPCoreCtx(ceob.iosDeviceDataEvent.x, ceob.iosDeviceDataEvent.y), 0.05d)=true then 'TRUE' else 'FALSE' end) as isContain
from ChanEnabledOutputBuffer[NOW] as ceob, GIPCacheGeoms as cacheGeoms
This query allows me to get all relationships between position and all configured geoms. That helps me after to make pattern to only get an event when relationship is changing (from IN to OUT and from OUT to IN)
Have you an idea ?
You have my phone number to call me!
regards,
Olivier