Skip to main content

dataset_versions

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

Overview

Namedataset_versions
TypeResource
Idgoogle.aiplatform.dataset_versions

Fields

NameDatatypeDescription
namestringOutput only. Identifier. The resource name of the DatasetVersion.
bigQueryDatasetNamestringOutput only. Name of the associated BigQuery dataset.
createTimestringOutput only. Timestamp when this DatasetVersion was created.
displayNamestringThe user-defined name of the DatasetVersion. The name can be up to 128 characters long and can consist of any UTF-8 characters.
etagstringUsed to perform consistent read-modify-write updates. If not set, a blind "overwrite" update happens.
metadataanyRequired. Output only. Additional information about the DatasetVersion.
modelReferencestringOutput only. Reference to the public base model last used by the dataset version. Only set for prompt dataset versions.
satisfiesPzibooleanOutput only. Reserved for future use.
satisfiesPzsbooleanOutput only. Reserved for future use.
updateTimestringOutput only. Timestamp when this DatasetVersion was last updated.

Methods

NameAccessible byRequired ParamsDescription
getSELECTdatasetVersionsId, datasetsId, locationsId, projectsIdGets a Dataset version.
listSELECTdatasetsId, locationsId, projectsIdLists DatasetVersions in a Dataset.
createINSERTdatasetsId, locationsId, projectsIdCreate a version from a Dataset.
deleteDELETEdatasetVersionsId, datasetsId, locationsId, projectsIdDeletes a Dataset version.
patchUPDATEdatasetVersionsId, datasetsId, locationsId, projectsIdUpdates a DatasetVersion.
restoreEXECdatasetVersionsId, datasetsId, locationsId, projectsIdRestores a dataset version.

SELECT examples

Lists DatasetVersions in a Dataset.

SELECT
name,
bigQueryDatasetName,
createTime,
displayName,
etag,
metadata,
modelReference,
satisfiesPzi,
satisfiesPzs,
updateTime
FROM google.aiplatform.dataset_versions
WHERE datasetsId = '{{ datasetsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

INSERT example

Use the following StackQL query and manifest file to create a new dataset_versions resource.

/*+ create */
INSERT INTO google.aiplatform.dataset_versions (
datasetsId,
locationsId,
projectsId,
etag,
displayName
)
SELECT
'{{ datasetsId }}',
'{{ locationsId }}',
'{{ projectsId }}',
'{{ etag }}',
'{{ displayName }}'
;

UPDATE example

Updates a dataset_versions resource.

/*+ update */
UPDATE google.aiplatform.dataset_versions
SET
etag = '{{ etag }}',
displayName = '{{ displayName }}'
WHERE
datasetVersionsId = '{{ datasetVersionsId }}'
AND datasetsId = '{{ datasetsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';

DELETE example

Deletes the specified dataset_versions resource.

/*+ delete */
DELETE FROM google.aiplatform.dataset_versions
WHERE datasetVersionsId = '{{ datasetVersionsId }}'
AND datasetsId = '{{ datasetsId }}'
AND locationsId = '{{ locationsId }}'
AND projectsId = '{{ projectsId }}';