changesets
Creates, updates, deletes, gets or lists a changesets resource.
Overview
| Name | changesets |
| Type | Resource |
| Id | aws.finspace_data.changesets |
Fields
The following fields are returned by SELECT queries:
- get_changeset
- list_changesets
| Name | Datatype | Description |
|---|---|---|
active_from_timestamp | integer (int64) | Milliseconds since UTC epoch |
active_until_timestamp | integer (int64) | Milliseconds since UTC epoch |
change_type | string | Indicates how the given change will be applied to the dataset. (REPLACE, APPEND, MODIFY) |
changeset_arn | string | The ARN identifier of the Changeset. |
changeset_id | string | ID used to identify a Changeset |
create_time | integer (int64) | Milliseconds since UTC epoch |
dataset_id | string | ID for a given Dataset |
error_info | object | The structure with error messages. |
format_params | object | Structure of the source file(s). |
source_params | object | Options that define the location of the data being ingested. |
status | string | The status of Changeset creation operation. (PENDING, FAILED, SUCCESS, RUNNING, STOP_REQUESTED) |
updated_by_changeset_id | string | ID used to identify a Changeset |
updates_changeset_id | string | ID used to identify a Changeset |
| Name | Datatype | Description |
|---|---|---|
active_from_timestamp | integer (int64) | Beginning time from which the Changeset is active. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000. |
active_until_timestamp | integer (int64) | Time until which the Changeset is active. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000. |
change_type | string | Indicates how the given change will be applied to the dataset. (REPLACE, APPEND, MODIFY) |
changeset_arn | string | The ARN identifier of the Changeset. |
changeset_id | string | The unique identifier for a Changeset. |
create_time | integer (int64) | The timestamp at which the Changeset was created in FinSpace. The value is determined as epoch time in milliseconds. For example, the value for Monday, November 1, 2021 12:00:00 PM UTC is specified as 1635768000000. |
dataset_id | string | ID for a given Dataset |
error_info | object | The structure with error messages. |
format_params | object | Options that define the structure of the source file(s). |
source_params | object | Options that define the location of the data being ingested. |
status | string | Status of the Changeset ingestion. PENDING – Changeset is pending creation. FAILED – Changeset creation has failed. SUCCESS – Changeset creation has succeeded. RUNNING – Changeset creation is running. STOP_REQUESTED – User requested Changeset creation to stop. (PENDING, FAILED, SUCCESS, RUNNING, STOP_REQUESTED) |
updated_by_changeset_id | string | The unique identifier of the updated Changeset. |
updates_changeset_id | string | The unique identifier of the Changeset that is updated. |
Methods
The following methods are available for this resource:
| Name | Accessible by | Required Params | Optional Params | Description |
|---|---|---|---|---|
get_changeset | select | dataset_id, changeset_id, region | Get information about a Changeset. | |
list_changesets | select | dataset_id, region | maxResults, nextToken | Lists the FinSpace Changesets for a Dataset. |
create_changeset | insert | dataset_id, region, changeType, sourceParams, formatParams | Creates a new Changeset in a FinSpace Dataset. | |
update_changeset | update | dataset_id, changeset_id, region, sourceParams, formatParams | Updates a FinSpace Changeset. |
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.
| Name | Datatype | Description |
|---|---|---|
changeset_id | string | The unique identifier for the Changeset to update. |
dataset_id | string | The unique identifier for the FinSpace Dataset in which the Changeset is created. |
region | string | AWS region (default: us-east-1) |
maxResults | integer | The maximum number of results per page. |
nextToken | string | A token that indicates where a results page should begin. |
SELECT examples
- get_changeset
- list_changesets
Get information about a Changeset.
SELECT
active_from_timestamp,
active_until_timestamp,
change_type,
changeset_arn,
changeset_id,
create_time,
dataset_id,
error_info,
format_params,
source_params,
status,
updated_by_changeset_id,
updates_changeset_id
FROM aws.finspace_data.changesets
WHERE dataset_id = '{{ dataset_id }}' -- required
AND changeset_id = '{{ changeset_id }}' -- required
AND region = '{{ region }}' -- required
;
Lists the FinSpace Changesets for a Dataset.
SELECT
active_from_timestamp,
active_until_timestamp,
change_type,
changeset_arn,
changeset_id,
create_time,
dataset_id,
error_info,
format_params,
source_params,
status,
updated_by_changeset_id,
updates_changeset_id
FROM aws.finspace_data.changesets
WHERE dataset_id = '{{ dataset_id }}' -- required
AND region = '{{ region }}' -- required
AND maxResults = '{{ maxResults }}'
AND nextToken = '{{ nextToken }}'
;
INSERT examples
- create_changeset
- Manifest
Creates a new Changeset in a FinSpace Dataset.
INSERT INTO aws.finspace_data.changesets (
clientToken,
changeType,
sourceParams,
formatParams,
dataset_id,
region
)
SELECT
'{{ clientToken }}',
'{{ changeType }}' /* required */,
'{{ sourceParams }}' /* required */,
'{{ formatParams }}' /* required */,
'{{ dataset_id }}',
'{{ region }}'
RETURNING
changeset_id,
dataset_id
;
# Description fields are for documentation purposes
- name: changesets
props:
- name: dataset_id
value: "{{ dataset_id }}"
description: Required parameter for the changesets resource.
- name: region
value: "{{ region }}"
description: Required parameter for the changesets resource.
- name: clientToken
value: "{{ clientToken }}"
description: |
Idempotence Token for API operations
- name: changeType
value: "{{ changeType }}"
description: |
Indicates how the given change will be applied to the dataset.
valid_values: ['REPLACE', 'APPEND', 'MODIFY']
- name: sourceParams
value: "{{ sourceParams }}"
description: |
Source Parameters of a Changeset
- name: formatParams
value: "{{ formatParams }}"
description: |
Format Parameters of a Changeset
UPDATE examples
- update_changeset
Updates a FinSpace Changeset.
UPDATE aws.finspace_data.changesets
SET
clientToken = '{{ clientToken }}',
sourceParams = '{{ sourceParams }}',
formatParams = '{{ formatParams }}'
WHERE
dataset_id = '{{ dataset_id }}' --required
AND changeset_id = '{{ changeset_id }}' --required
AND region = '{{ region }}' --required
AND sourceParams = '{{ sourceParams }}' --required
AND formatParams = '{{ formatParams }}' --required
RETURNING
changeset_id,
dataset_id;