Skip to main content

data_lake_datasets

Creates, updates, deletes, gets or lists a data_lake_datasets resource.

Overview

Namedata_lake_datasets
TypeResource
Idaws.supplychain.data_lake_datasets

Fields

The following fields are returned by SELECT queries:

NameDatatypeDescription
namestringThe name of the dataset. For asc namespace, the name must be one of the supported data entities under https:​//docs.aws.amazon.com/aws-supply-chain/latest/userguide/data-model-asc.html. (pattern: <code>[a-z0-9_]+</code>)
arnstringThe arn of the dataset. (pattern: <code>arn:aws:scn(?::([a-z0-9-]+):([0-9]+):instance)?/([a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12})[-_./A-Za-z0-9]*</code>)
created_timestring (date-time)The creation time of the dataset.
descriptionstringThe description of the dataset.
instance_idstringThe Amazon Web Services Supply Chain instance identifier. (pattern: <code>[a-f0-9]{8}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{4}-[a-f0-9]{12}</code>)
last_modified_timestring (date-time)The last modified time of the dataset.
namespacestringThe namespace of the dataset, besides the custom defined namespace, every instance comes with below pre-defined namespaces: asc - For information on the Amazon Web Services Supply Chain supported datasets see https:​//docs.aws.amazon.com/aws-supply-chain/latest/userguide/data-model-asc.html. default - For datasets with custom user-defined schemas. (pattern: <code>[a-z0-9_]+</code>)
partition_specobjectThe partition specification for a dataset.
schemaobjectThe schema details of the dataset. Note that for AWS Supply Chain dataset under asc namespace, it may have internal fields like connection_id that will be auto populated by data ingestion methods.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
get_data_lake_datasetselectinstance_id, namespace, name, regionEnables you to programmatically view an Amazon Web Services Supply Chain data lake dataset. Developers can view the data lake dataset information such as namespace, schema, and so on for a given instance ID, namespace, and dataset name.
list_data_lake_datasetsselectinstance_id, namespace, regionnextToken, maxResultsEnables you to programmatically view the list of Amazon Web Services Supply Chain data lake datasets. Developers can view the datasets and the corresponding information such as namespace, schema, and so on for a given instance ID and namespace.
create_data_lake_datasetinsertinstance_id, namespace, name, regionEnables you to programmatically create an Amazon Web Services Supply Chain data lake dataset. Developers can create the datasets using their pre-defined or custom schema for a given instance ID, namespace, and dataset name.
update_data_lake_datasetupdateinstance_id, namespace, name, regionEnables you to programmatically update an Amazon Web Services Supply Chain data lake dataset. Developers can update the description of a data lake dataset for a given instance ID, namespace, and dataset name.
delete_data_lake_datasetdeleteinstance_id, namespace, name, regionEnables you to programmatically delete an Amazon Web Services Supply Chain data lake dataset. Developers can delete the existing datasets for a given instance ID, namespace, and instance name.

Parameters

Parameters can be passed in the WHERE clause of a query. Check the Methods section to see which parameters are required or optional for each operation.

NameDatatypeDescription
instance_idstringThe AWS Supply Chain instance identifier.
namestringThe name of the dataset. For asc namespace, the name must be one of the supported data entities under https:​//docs.aws.amazon.com/aws-supply-chain/latest/userguide/data-model-asc.html.
namespacestringThe namespace of the dataset, besides the custom defined namespace, every instance comes with below pre-defined namespaces: asc - For information on the Amazon Web Services Supply Chain supported datasets see https:​//docs.aws.amazon.com/aws-supply-chain/latest/userguide/data-model-asc.html. default - For datasets with custom user-defined schemas.
regionstringAWS region (default: us-east-1)
maxResultsintegerThe max number of datasets to fetch in this paginated request.
nextTokenstringThe pagination token to fetch next page of datasets.

SELECT examples

Enables you to programmatically view an Amazon Web Services Supply Chain data lake dataset. Developers can view the data lake dataset information such as namespace, schema, and so on for a given instance ID, namespace, and dataset name.

SELECT
name,
arn,
created_time,
description,
instance_id,
last_modified_time,
namespace,
partition_spec,
schema
FROM aws.supplychain.data_lake_datasets
WHERE instance_id = '{{ instance_id }}' -- required
AND namespace = '{{ namespace }}' -- required
AND name = '{{ name }}' -- required
AND region = '{{ region }}' -- required
;

INSERT examples

Enables you to programmatically create an Amazon Web Services Supply Chain data lake dataset. Developers can create the datasets using their pre-defined or custom schema for a given instance ID, namespace, and dataset name.

INSERT INTO aws.supplychain.data_lake_datasets (
schema,
description,
partitionSpec,
tags,
instance_id,
namespace,
name,
region
)
SELECT
'{{ schema }}',
'{{ description }}',
'{{ partitionSpec }}',
'{{ tags }}',
'{{ instance_id }}',
'{{ namespace }}',
'{{ name }}',
'{{ region }}'
RETURNING
dataset
;

UPDATE examples

Enables you to programmatically update an Amazon Web Services Supply Chain data lake dataset. Developers can update the description of a data lake dataset for a given instance ID, namespace, and dataset name.

UPDATE aws.supplychain.data_lake_datasets
SET
description = '{{ description }}'
WHERE
instance_id = '{{ instance_id }}' --required
AND namespace = '{{ namespace }}' --required
AND name = '{{ name }}' --required
AND region = '{{ region }}' --required
RETURNING
dataset;

DELETE examples

Enables you to programmatically delete an Amazon Web Services Supply Chain data lake dataset. Developers can delete the existing datasets for a given instance ID, namespace, and instance name.

DELETE FROM aws.supplychain.data_lake_datasets
WHERE instance_id = '{{ instance_id }}' --required
AND namespace = '{{ namespace }}' --required
AND name = '{{ name }}' --required
AND region = '{{ region }}' --required
;