Use the DK layer.Loop enumerator with proper parameters consistent with the DE-9IM mathematical module for geometric relations. The DE-9IM spatial querying features work with both shape layers and SQL database layers, including spatial databases.
When used with spatial database layers (Oracle Spatial, PostGIS, ESRI ArcSDE, MSSQL Spatial Server, IBM DB2 Spatial Extender, Geomedia SQQL Server Spatial, etc.), which can perform spatial querying on the server side, the TatukGIS product passes spatial queries to the server whenever possible. If the spatial server supports only a subset of the DE-9IM operations supported by TatukGIS, the TatukGIS software intelligently passes to the server queries that the server is capable of processing, and interprets other queries locally.
The DE-9IM model is explained in detail in the DK Guide.