Skip to main content

relations

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

Overview

Namerelations
TypeResource
Idgoogle.migrationcenter.relations

Fields

The following fields are returned by SELECT queries:

Successful response

NameDatatypeDescription
namestringOutput only. Identifier. The identifier of the relation.
createTimestring (google-datetime)Output only. The timestamp when the relation was created.
dstAssetstringOutput only. The destination asset name in the relation.
srcAssetstringOutput only. The source asset name in the relation.
typestringOptional. The type of the relation.

Methods

The following methods are available for this resource:

NameAccessible byRequired ParamsOptional ParamsDescription
getselectprojectsId, locationsId, relationsIdGets the details of an relation.
listselectprojectsId, locationsIdpageSize, pageToken, filter, orderByLists all the relations in a given project and location.

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
locationsIdstring
projectsIdstring
relationsIdstring
filterstring
orderBystring
pageSizeinteger (int32)
pageTokenstring

SELECT examples

Gets the details of an relation.

SELECT
name,
createTime,
dstAsset,
srcAsset,
type
FROM google.migrationcenter.relations
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND relationsId = '{{ relationsId }}' -- required;