Skip to main content

datasets

Creates, updates, deletes or gets a dataset resource or lists datasets in a region

Overview

Namedatasets
TypeResource
DescriptionResource Type Definition for AWS::Forecast::Dataset
Idawscc.forecast.datasets

Fields

NameDatatypeDescription
arnstring
dataset_namestringA name for the dataset
dataset_typestringThe dataset type
data_frequencystringFrequency of data collection. This parameter is required for RELATED_TIME_SERIES
domainstringThe domain associated with the dataset
encryption_configobject
schemaobject
tagsarray
regionstringAWS region.

For more information, see AWS::Forecast::Dataset.

Methods

NameResourceAccessible byRequired Params
create_resourcedatasetsINSERTDatasetName, DatasetType, Domain, Schema, region
delete_resourcedatasetsDELETEIdentifier, region
list_resourcesdatasets_list_onlySELECTregion
get_resourcedatasetsSELECTIdentifier, region

SELECT examples

Gets all properties from an individual dataset.

SELECT
region,
arn,
dataset_name,
dataset_type,
data_frequency,
domain,
encryption_config,
schema,
tags
FROM awscc.forecast.datasets
WHERE
region = '{{ region }}' AND
Identifier = '{{ arn }}';

INSERT example

Use the following StackQL query and manifest file to create a new dataset resource, using stack-deploy.

/*+ create */
INSERT INTO awscc.forecast.datasets (
DatasetName,
DatasetType,
Domain,
Schema,
region
)
SELECT
'{{ dataset_name }}',
'{{ dataset_type }}',
'{{ domain }}',
'{{ schema }}',
'{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

DELETE example

/*+ delete */
DELETE FROM awscc.forecast.datasets
WHERE
Identifier = '{{ arn }}' AND
region = '{{ region }}'
RETURNING
ErrorCode,
EventTime,
Identifier,
Operation,
OperationStatus,
RequestToken,
ResourceModel,
RetryAfter,
StatusMessage,
TypeName
;

Additional Parameters

Mutable resources in the Cloud Control provider support additional optional parameters which can be supplied with INSERT, UPDATE, or DELETE operations. These include:

ParameterDescription
ClientToken
A unique identifier to ensure the idempotency of the resource request.This allows the provider to accurately distinguish between retries and new requests.
A client token is valid for 36 hours once used.
After that, a resource request with the same client token is treated as a new request.
If you do not specify a client token, one is generated for inclusion in the request.
RoleArn
The ARN of the IAM role used to perform this resource operation.The role specified must have the permissions required for this operation.
If you do not specify a role, a temporary session is created using your AWS user credentials.
TypeVersionId
For private resource types, the type version to use in this resource operation.If you do not specify a resource version, the default version is used.

Permissions

To operate on the datasets resource, the following permissions are required:

forecast:CreateDataset