pub struct CreateFunction {Show 19 fields
pub or_alter: bool,
pub or_replace: bool,
pub temporary: bool,
pub if_not_exists: bool,
pub aggregate: bool,
pub table_function: bool,
pub name: ObjectName,
pub args: Option<Vec<OperateFunctionArg>>,
pub return_type: Option<DataType>,
pub function_body: Option<CreateFunctionBody>,
pub behavior: Option<FunctionBehavior>,
pub called_on_null: Option<FunctionCalledOnNull>,
pub parallel: Option<FunctionParallel>,
pub using: Option<CreateFunctionUsing>,
pub language: Option<Ident>,
pub determinism_specifier: Option<FunctionDeterminismSpecifier>,
pub options: Option<Vec<SqlOption>>,
pub remote_connection: Option<ObjectName>,
pub sql_security: Option<SqlSecurity>,
}Fields§
§or_alter: boolTrue if this is a CREATE OR ALTER FUNCTION statement
or_replace: bool§temporary: bool§if_not_exists: bool§aggregate: boolTrue if this is an aggregate function (BigQuery)
table_function: boolTrue if this is a table function (BigQuery)
name: ObjectName§args: Option<Vec<OperateFunctionArg>>§return_type: Option<DataType>§function_body: Option<CreateFunctionBody>The expression that defines the function.
Examples:
AS ((SELECT 1))
AS "console.log();"behavior: Option<FunctionBehavior>§called_on_null: Option<FunctionCalledOnNull>CALLED ON NULL INPUT | RETURNS NULL ON NULL INPUT | STRICT
parallel: Option<FunctionParallel>PARALLEL { UNSAFE | RESTRICTED | SAFE }
using: Option<CreateFunctionUsing>USING … (Hive only)
language: Option<Ident>Language used in a UDF definition.
Example:
CREATE FUNCTION foo() LANGUAGE js AS "console.log();"determinism_specifier: Option<FunctionDeterminismSpecifier>Determinism keyword used for non-sql UDF definitions.
options: Option<Vec<SqlOption>>List of options for creating the function.
remote_connection: Option<ObjectName>Connection resource for a remote function.
Example:
CREATE FUNCTION foo()
RETURNS FLOAT64
REMOTE WITH CONNECTION us.myconnectionsql_security: Option<SqlSecurity>SQL SECURITY clause (DEFINER or INVOKER)
Trait Implementations§
Source§impl Clone for CreateFunction
impl Clone for CreateFunction
Source§fn clone(&self) -> CreateFunction
fn clone(&self) -> CreateFunction
Returns a duplicate of the value. Read more
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
Performs copy-assignment from
source. Read moreSource§impl Debug for CreateFunction
impl Debug for CreateFunction
Source§impl<'de> Deserialize<'de> for CreateFunction
impl<'de> Deserialize<'de> for CreateFunction
Source§fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
fn deserialize<__D>(__deserializer: __D) -> Result<Self, __D::Error>where
__D: Deserializer<'de>,
Deserialize this value from the given Serde deserializer. Read more
Source§impl Display for CreateFunction
impl Display for CreateFunction
Source§impl From<CreateFunction> for Statement
impl From<CreateFunction> for Statement
Source§fn from(c: CreateFunction) -> Self
fn from(c: CreateFunction) -> Self
Converts to this type from the input type.
Source§impl Hash for CreateFunction
impl Hash for CreateFunction
Source§impl Ord for CreateFunction
impl Ord for CreateFunction
Source§fn cmp(&self, other: &CreateFunction) -> Ordering
fn cmp(&self, other: &CreateFunction) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Compares and returns the maximum of two values. Read more
Source§impl PartialEq for CreateFunction
impl PartialEq for CreateFunction
Source§impl PartialOrd for CreateFunction
impl PartialOrd for CreateFunction
Source§impl Serialize for CreateFunction
impl Serialize for CreateFunction
Source§impl Visit for CreateFunction
impl Visit for CreateFunction
Source§impl VisitMut for CreateFunction
impl VisitMut for CreateFunction
fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
impl Eq for CreateFunction
impl StructuralPartialEq for CreateFunction
Auto Trait Implementations§
impl Freeze for CreateFunction
impl RefUnwindSafe for CreateFunction
impl Send for CreateFunction
impl Sync for CreateFunction
impl Unpin for CreateFunction
impl UnwindSafe for CreateFunction
Blanket Implementations§
Source§impl<T> BorrowMut<T> for Twhere
T: ?Sized,
impl<T> BorrowMut<T> for Twhere
T: ?Sized,
Source§fn borrow_mut(&mut self) -> &mut T
fn borrow_mut(&mut self) -> &mut T
Mutably borrows from an owned value. Read more