pub enum GrantObjects {
Show 28 variants
AllSequencesInSchema {
schemas: Vec<ObjectName>,
},
AllTablesInSchema {
schemas: Vec<ObjectName>,
},
AllViewsInSchema {
schemas: Vec<ObjectName>,
},
AllMaterializedViewsInSchema {
schemas: Vec<ObjectName>,
},
AllExternalTablesInSchema {
schemas: Vec<ObjectName>,
},
AllFunctionsInSchema {
schemas: Vec<ObjectName>,
},
FutureSchemasInDatabase {
databases: Vec<ObjectName>,
},
FutureTablesInSchema {
schemas: Vec<ObjectName>,
},
FutureViewsInSchema {
schemas: Vec<ObjectName>,
},
FutureExternalTablesInSchema {
schemas: Vec<ObjectName>,
},
FutureMaterializedViewsInSchema {
schemas: Vec<ObjectName>,
},
FutureSequencesInSchema {
schemas: Vec<ObjectName>,
},
Databases(Vec<ObjectName>),
Schemas(Vec<ObjectName>),
Sequences(Vec<ObjectName>),
Tables(Vec<ObjectName>),
Views(Vec<ObjectName>),
Warehouses(Vec<ObjectName>),
Integrations(Vec<ObjectName>),
ResourceMonitors(Vec<ObjectName>),
Users(Vec<ObjectName>),
ComputePools(Vec<ObjectName>),
Connections(Vec<ObjectName>),
FailoverGroup(Vec<ObjectName>),
ReplicationGroup(Vec<ObjectName>),
ExternalVolumes(Vec<ObjectName>),
Procedure {
name: ObjectName,
arg_types: Vec<DataType>,
},
Function {
name: ObjectName,
arg_types: Vec<DataType>,
},
}Expand description
Objects on which privileges are granted in a GRANT statement.
Variants§
AllSequencesInSchema
Grant privileges on ALL SEQUENCES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
AllTablesInSchema
Grant privileges on ALL TABLES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
AllViewsInSchema
Grant privileges on ALL VIEWS IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
AllMaterializedViewsInSchema
Grant privileges on ALL MATERIALIZED VIEWS IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
AllExternalTablesInSchema
Grant privileges on ALL EXTERNAL TABLES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
AllFunctionsInSchema
Grant privileges on ALL FUNCTIONS IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
FutureSchemasInDatabase
Grant privileges on FUTURE SCHEMAS IN DATABASE <database_name> [, ...]
Fields
databases: Vec<ObjectName>The target database names.
FutureTablesInSchema
Grant privileges on FUTURE TABLES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
FutureViewsInSchema
Grant privileges on FUTURE VIEWS IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
FutureExternalTablesInSchema
Grant privileges on FUTURE EXTERNAL TABLES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
FutureMaterializedViewsInSchema
Grant privileges on FUTURE MATERIALIZED VIEWS IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
FutureSequencesInSchema
Grant privileges on FUTURE SEQUENCES IN SCHEMA <schema_name> [, ...]
Fields
schemas: Vec<ObjectName>The target schema names.
Databases(Vec<ObjectName>)
Grant privileges on specific databases
Schemas(Vec<ObjectName>)
Grant privileges on specific schemas
Sequences(Vec<ObjectName>)
Grant privileges on specific sequences
Tables(Vec<ObjectName>)
Grant privileges on specific tables
Views(Vec<ObjectName>)
Grant privileges on specific views
Warehouses(Vec<ObjectName>)
Grant privileges on specific warehouses
Integrations(Vec<ObjectName>)
Grant privileges on specific integrations
ResourceMonitors(Vec<ObjectName>)
Grant privileges on resource monitors
Users(Vec<ObjectName>)
Grant privileges on users
ComputePools(Vec<ObjectName>)
Grant privileges on compute pools
Connections(Vec<ObjectName>)
Grant privileges on connections
FailoverGroup(Vec<ObjectName>)
Grant privileges on failover groups
ReplicationGroup(Vec<ObjectName>)
Grant privileges on replication group
ExternalVolumes(Vec<ObjectName>)
Grant privileges on external volumes
Procedure
Grant privileges on a procedure. In dialects that support overloading, the argument types must be specified.
For example:
GRANT USAGE ON PROCEDURE foo(varchar) TO ROLE role1
Fields
name: ObjectNameThe procedure name.
Function
Grant privileges on a function. In dialects that support overloading, the argument types must be specified.
For example:
GRANT USAGE ON FUNCTION foo(varchar) TO ROLE role1
Fields
name: ObjectNameThe function name.
Trait Implementations§
Source§impl Clone for GrantObjects
impl Clone for GrantObjects
Source§fn clone(&self) -> GrantObjects
fn clone(&self) -> GrantObjects
1.0.0 · Source§fn clone_from(&mut self, source: &Self)
fn clone_from(&mut self, source: &Self)
source. Read moreSource§impl Debug for GrantObjects
impl Debug for GrantObjects
Source§impl Display for GrantObjects
impl Display for GrantObjects
Source§impl Hash for GrantObjects
impl Hash for GrantObjects
Source§impl Ord for GrantObjects
impl Ord for GrantObjects
Source§fn cmp(&self, other: &GrantObjects) -> Ordering
fn cmp(&self, other: &GrantObjects) -> Ordering
1.21.0 · Source§fn max(self, other: Self) -> Selfwhere
Self: Sized,
fn max(self, other: Self) -> Selfwhere
Self: Sized,
Source§impl PartialEq for GrantObjects
impl PartialEq for GrantObjects
Source§impl PartialOrd for GrantObjects
impl PartialOrd for GrantObjects
Source§impl Visit for GrantObjects
impl Visit for GrantObjects
Source§impl VisitMut for GrantObjects
impl VisitMut for GrantObjects
Source§fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
fn visit<V: VisitorMut>(&mut self, visitor: &mut V) -> ControlFlow<V::Break>
VisitorMut. Read more