target_projects
Creates, updates, deletes, gets or lists a target_projects
resource.
Overview
Name | target_projects |
Type | Resource |
Id | google.vmmigration.target_projects |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The name of the target project. |
createTime | string (google-datetime) | Output only. The time this target project resource was created (not related to when the Compute Engine project it points to was created). |
description | string | The target project's description. |
project | string | Required. The target project ID (number) or project name. |
updateTime | string (google-datetime) | Output only. The last time the target project resource was updated. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Output only. The name of the target project. |
createTime | string (google-datetime) | Output only. The time this target project resource was created (not related to when the Compute Engine project it points to was created). |
description | string | The target project's description. |
project | string | Required. The target project ID (number) or project name. |
updateTime | string (google-datetime) | Output only. The last time the target project resource was updated. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , locationsId , targetProjectsId | Gets details of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global . | |
list | select | projectsId , locationsId | pageSize , pageToken , filter , orderBy | Lists TargetProjects in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is global . |
create | insert | projectsId , locationsId | targetProjectId , requestId | Creates a new TargetProject in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is global . |
patch | update | projectsId , locationsId , targetProjectsId | updateMask , requestId | Updates the parameters of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global . |
delete | delete | projectsId , locationsId , targetProjectsId | requestId | Deletes a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global . |
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 |
---|---|---|
locationsId | string | |
projectsId | string | |
targetProjectsId | string | |
filter | string | |
orderBy | string | |
pageSize | integer (int32) | |
pageToken | string | |
requestId | string | |
targetProjectId | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets details of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global
.
SELECT
name,
createTime,
description,
project,
updateTime
FROM google.vmmigration.target_projects
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND targetProjectsId = '{{ targetProjectsId }}' -- required;
Lists TargetProjects in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is global
.
SELECT
name,
createTime,
description,
project,
updateTime
FROM google.vmmigration.target_projects
WHERE projectsId = '{{ projectsId }}' -- required
AND locationsId = '{{ locationsId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}'
AND filter = '{{ filter }}'
AND orderBy = '{{ orderBy }}';
INSERT
examples
- create
- Manifest
Creates a new TargetProject in a given project. NOTE: TargetProject is a global resource; hence the only supported value for location is global
.
INSERT INTO google.vmmigration.target_projects (
data__project,
data__description,
projectsId,
locationsId,
targetProjectId,
requestId
)
SELECT
'{{ project }}',
'{{ description }}',
'{{ projectsId }}',
'{{ locationsId }}',
'{{ targetProjectId }}',
'{{ requestId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: target_projects
props:
- name: projectsId
value: string
description: Required parameter for the target_projects resource.
- name: locationsId
value: string
description: Required parameter for the target_projects resource.
- name: project
value: string
description: >
Required. The target project ID (number) or project name.
- name: description
value: string
description: >
The target project's description.
- name: targetProjectId
value: string
- name: requestId
value: string
UPDATE
examples
- patch
Updates the parameters of a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global
.
UPDATE google.vmmigration.target_projects
SET
data__project = '{{ project }}',
data__description = '{{ description }}'
WHERE
projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND targetProjectsId = '{{ targetProjectsId }}' --required
AND updateMask = '{{ updateMask}}'
AND requestId = '{{ requestId}}'
RETURNING
name,
done,
error,
metadata,
response;
DELETE
examples
- delete
Deletes a single TargetProject. NOTE: TargetProject is a global resource; hence the only supported value for location is global
.
DELETE FROM google.vmmigration.target_projects
WHERE projectsId = '{{ projectsId }}' --required
AND locationsId = '{{ locationsId }}' --required
AND targetProjectsId = '{{ targetProjectsId }}' --required
AND requestId = '{{ requestId }}';