You seem to have in mind some functionality that exists in Table that you would 
like replicated in TableFunction. Can you describe the Table functionality?

Are you aware of TableMacro? Maybe it is a bit more “plannable”.

Julian



> On Jan 5, 2017, at 8:05 AM, Julian Feinauer <[email protected]> 
> wrote:
> 
> Dear Folks,
> 
> 
> 
> I am currently working a lot with TableFunctions.
> 
> To get a bit more “freedom” about how the TableFunctions are called and when 
> I wanted to use a ConversionRule to convert the LogicalTableFunctionScan to 
> my custom CallingConvention (Similar to EnumerableTableFunctionScanRule, see 
> [1]).
> 
> 
> 
> But it seems not so easy to register the necessary Rule because I have no 
> instance of an AbstractRelNode that is loaded and hence no “register” 
> function that is called.
> 
> 
> 
> My Schema consists only of TableFunctions and it seems “hackish” to add a 
> Table or something else that registers my ConversionRules.
> 
> I see no way to “define” my TableFunctionScans as they are created by the 
> Parser as LogicalTableFunctionScans and I see no way to “define” them 
> directly.
> 
> The Connection is instantiated based on an json model (and a custom 
> SchemaFactory).
> 
> 
> 
> Are there any other ideas / possibilities to register ConversionRules in a 
> Connection / Schema that is created via a json model and consist only on 
> TableFunctions.
> 
> Or to “define” the TableFunctionScan directly in the Schema?
> 
> 
> 
> Thanks already!
> 
> Julian
> 
> 
> 
> [1] 
> https://github.com/apache/calcite/blob/0938c7b6d767e3242874d87a30d9112512d9243a/core/src/main/java/org/apache/calcite/adapter/enumerable/EnumerableTableFunctionScanRule.java
> 
> 
> 

Reply via email to