MCPcopy Create free account
hub / github.com/apache/datafusion / create_cte_work_table

Method create_cte_work_table

datafusion/core/src/execution/session_state.rs:2002–2011  ·  view source on GitHub ↗

Create a new CTE work table for a recursive CTE logical plan This table will be used in conjunction with a Worktable physical plan to read and write each iteration of a recursive CTE

(
        &self,
        name: &str,
        schema: arrow::datatypes::SchemaRef,
    )

Source from the content-addressed store, hash-verified

2000 /// This table will be used in conjunction with a Worktable physical plan
2001 /// to read and write each iteration of a recursive CTE
2002 fn create_cte_work_table(
2003 &self,
2004 name: &str,
2005 schema: arrow::datatypes::SchemaRef,
2006 ) -> datafusion_common::Result<Arc<dyn TableSource>> {
2007 let table = Arc::new(crate::datasource::cte_worktable::CteWorkTable::new(
2008 name, schema,
2009 ));
2010 Ok(provider_as_source(table))
2011 }
2012
2013 fn get_function_meta(&self, name: &str) -> Option<Arc<ScalarUDF>> {
2014 self.state.scalar_functions().get(name).cloned()

Callers

nothing calls this directly

Calls 2

newFunction · 0.85
provider_as_sourceFunction · 0.85

Tested by

no test coverage detected