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

Method register_udwf

datafusion/core/src/execution/context/mod.rs:1652–1654  ·  view source on GitHub ↗

Registers a window UDF within this context. Note in SQL queries, window function names are looked up using lowercase unless the query uses quotes. For example, - `SELECT MY_UDWF(x)...` will look for a window function named `"my_udwf"` - `SELECT "my_UDWF"(x)` will look for a window function named `"my_UDWF"`

(&self, f: WindowUDF)

Source from the content-addressed store, hash-verified

1650 /// - `SELECT MY_UDWF(x)...` will look for a window function named `"my_udwf"`
1651 /// - `SELECT "my_UDWF"(x)` will look for a window function named `"my_UDWF"`
1652 pub fn register_udwf(&self, f: WindowUDF) {
1653 self.state.write().register_udwf(Arc::new(f)).ok();
1654 }
1655
1656 #[cfg(feature = "sql")]
1657 /// Registers a [`RelationPlanner`] to customize SQL table-factor planning.

Callers 8

simple_udwfFunction · 0.45
advanced_udwfFunction · 0.45
roundtrip_windowFunction · 0.45
register_allFunction · 0.45
create_functionMethod · 0.45
registerMethod · 0.45
roundtrip_window_udfFunction · 0.45
register_allFunction · 0.45

Calls 2

newFunction · 0.85
writeMethod · 0.45

Tested by 3

roundtrip_windowFunction · 0.36
registerMethod · 0.36
roundtrip_window_udfFunction · 0.36