enum TableAction
Language | Type name |
---|---|
![]() | Amazon.CDK.AWS.Redshift.Alpha.TableAction |
![]() | github.com/aws/aws-cdk-go/awscdkredshiftalpha/v2#TableAction |
![]() | software.amazon.awscdk.services.redshift.alpha.TableAction |
![]() | aws_cdk.aws_redshift_alpha.TableAction |
![]() | @aws-cdk/aws-redshift-alpha ยป TableAction |
An action that a Redshift user can be granted privilege to perform on a table.
Example
const databaseName = 'databaseName';
const username = 'myuser'
const tableName = 'mytable'
const user = new User(this, 'User', {
username: username,
cluster: cluster,
databaseName: databaseName,
});
const table = new Table(this, 'Table', {
tableColumns: [{ name: 'col1', dataType: 'varchar(4)' }, { name: 'col2', dataType: 'float' }],
cluster: cluster,
databaseName: databaseName,
});
table.grant(user, TableAction.INSERT);
Members
Name | Description |
---|---|
SELECT | Grants privilege to select data from a table or view using a SELECT statement. |
INSERT | Grants privilege to load data into a table using an INSERT statement or a COPY statement. |
UPDATE | Grants privilege to update a table column using an UPDATE statement. |
DELETE | Grants privilege to delete a data row from a table. |
DROP | Grants privilege to drop a table. |
REFERENCES | Grants privilege to create a foreign key constraint. |
ALL | Grants all available privileges at once to the specified user or user group. |
SELECT
Grants privilege to select data from a table or view using a SELECT statement.
INSERT
Grants privilege to load data into a table using an INSERT statement or a COPY statement.
UPDATE
Grants privilege to update a table column using an UPDATE statement.
DELETE
Grants privilege to delete a data row from a table.
DROP
Grants privilege to drop a table.
REFERENCES
Grants privilege to create a foreign key constraint.
You need to grant this privilege on both the referenced table and the referencing table; otherwise, the user can't create the constraint.
ALL
Grants all available privileges at once to the specified user or user group.