org.eigenbase.relopt
Interface RelOptQuery.DeferredLookup

Enclosing class:
RelOptQuery

public static interface RelOptQuery.DeferredLookup

Contains the information necessary to repeat a call to SqlToRelConverter.Blackboard.lookup(int, org.eigenbase.sql2rel.SqlToRelConverter.LookupContext).


Method Summary
 RexFieldAccess getFieldAccess(String name)
          Creates an expression which accesses a particular field of this lookup.
 

Method Detail

getFieldAccess

RexFieldAccess getFieldAccess(String name)
Creates an expression which accesses a particular field of this lookup.

For example, when resolving

 select *
 from dept
 where exists (
   select *
   from emp
   where deptno = dept.deptno
   and specialty = 'Karate')
the expression dept.deptno would be handled using a deferred lookup for dept (because the sub-query is validated before the outer query) and the translator would call getFieldAccess("DEPTNO") on that lookup.

Parameters:
name - Name of field
Returns:
Expression which retrieves the given field of this lookup's correlating variable