Views and Joins Views and Schemas

18-24 Oracle Complex Event Processing CQL Language Reference The following predicate is invalid because arithmetic operations are not allowed on cache key attributes: ... CACHE.C1 + 5 = S.C1 AND CACHE.C2 = S.C2 ... 18.5.1.3 No Full Scans The complex predicate must not require a full scan of the cache. Assume that your cache has cache key C1. The following predicates are invalid. Because they do not use the cache key attribute in comparisons, they must scan through the whole cache which is not allowed. ... CACHE.C2 = S.C1 ... ... CACHE.C2 S.C1 ... ... S.C1 = S.C2 ... ... S.C1 = CACHE.C2 AND S.C2 = CACHE.C2 ... The following predicates are also invalid. Although they do use the cache key attribute in comparisons, they use inequality operations that must scan through the whole cache which is not allowed. ... CACHE.C1 = S.C1 ... ... CACHE.C1 5 ... ... CACHE.C1 + 5 = S.C1 ... The following predicate is also invalid. Although they do use the cache key attribute in comparisons, the first subclause referring to the cache attributes does not refer to the cache key attribute in this example, C1. That is, the first subclause refers to C2 which is not a cache key and the cache key comparison subclause CACHE.C1 = S.C1 appears after the non-key comparison subclause. ... CACHE.C2 = S.C2 AND CACHE.C1 = S.C1 ... 18.5.1.4 Multiple Conditions and Inequality To support multiple conditions, inequality, or both, you must make the first sub-clause an equality predicate comparing a cache key value and specify the rest of the predicate subclauses separated by one AND operator. The following are valid predicates: ... S.c1 = 5 AND CACHE.C1 = S.C1 AND CACHE.C2 S.C2 ... ... CACHE.C1 = S.C1 AND CACHE.C2 = S.C2 ... ... S.c1 = 5 AND CACHE.C1 = S.C1 AND CACHE.C2 = S.C2 ... 18.6 Oracle CQL Queries and Relational Database Tables You can access a relational database table from an Oracle CQL query using: ■ table source: using a table source, you may join a stream only with a NOW window and only to a single database table.