logical_views
Creates, updates, deletes, gets or lists a logical_views
resource.
Overview
Name | logical_views |
Type | Resource |
Id | google.bigtableadmin.logical_views |
Fields
The following fields are returned by SELECT
queries:
- get
- list
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. The unique name of the logical view. Format: projects/{project}/instances/{instance}/logicalViews/{logical_view} |
deletionProtection | boolean | Optional. Set to true to make the LogicalView protected against deletion. |
etag | string | Optional. The etag for this logical view. This may be sent on update requests to ensure that the client has an up-to-date value before proceeding. The server returns an ABORTED error on a mismatched etag. |
query | string | Required. The logical view's select query. |
Successful response
Name | Datatype | Description |
---|---|---|
name | string | Identifier. The unique name of the logical view. Format: projects/{project}/instances/{instance}/logicalViews/{logical_view} |
deletionProtection | boolean | Optional. Set to true to make the LogicalView protected against deletion. |
etag | string | Optional. The etag for this logical view. This may be sent on update requests to ensure that the client has an up-to-date value before proceeding. The server returns an ABORTED error on a mismatched etag. |
query | string | Required. The logical view's select query. |
Methods
The following methods are available for this resource:
Name | Accessible by | Required Params | Optional Params | Description |
---|---|---|---|---|
get | select | projectsId , instancesId , logicalViewsId | Gets information about a logical view. | |
list | select | projectsId , instancesId | pageSize , pageToken | Lists information about logical views in an instance. |
create | insert | projectsId , instancesId | logicalViewId | Creates a logical view within an instance. |
patch | update | projectsId , instancesId , logicalViewsId | updateMask | Updates a logical view within an instance. |
delete | delete | projectsId , instancesId , logicalViewsId | etag | Deletes a logical view from an instance. |
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 |
---|---|---|
instancesId | string | |
logicalViewsId | string | |
projectsId | string | |
etag | string | |
logicalViewId | string | |
pageSize | integer (int32) | |
pageToken | string | |
updateMask | string (google-fieldmask) |
SELECT
examples
- get
- list
Gets information about a logical view.
SELECT
name,
deletionProtection,
etag,
query
FROM google.bigtableadmin.logical_views
WHERE projectsId = '{{ projectsId }}' -- required
AND instancesId = '{{ instancesId }}' -- required
AND logicalViewsId = '{{ logicalViewsId }}' -- required;
Lists information about logical views in an instance.
SELECT
name,
deletionProtection,
etag,
query
FROM google.bigtableadmin.logical_views
WHERE projectsId = '{{ projectsId }}' -- required
AND instancesId = '{{ instancesId }}' -- required
AND pageSize = '{{ pageSize }}'
AND pageToken = '{{ pageToken }}';
INSERT
examples
- create
- Manifest
Creates a logical view within an instance.
INSERT INTO google.bigtableadmin.logical_views (
data__name,
data__query,
data__etag,
data__deletionProtection,
projectsId,
instancesId,
logicalViewId
)
SELECT
'{{ name }}',
'{{ query }}',
'{{ etag }}',
{{ deletionProtection }},
'{{ projectsId }}',
'{{ instancesId }}',
'{{ logicalViewId }}'
RETURNING
name,
done,
error,
metadata,
response
;
# Description fields are for documentation purposes
- name: logical_views
props:
- name: projectsId
value: string
description: Required parameter for the logical_views resource.
- name: instancesId
value: string
description: Required parameter for the logical_views resource.
- name: name
value: string
description: >
Identifier. The unique name of the logical view. Format: `projects/{project}/instances/{instance}/logicalViews/{logical_view}`
- name: query
value: string
description: >
Required. The logical view's select query.
- name: etag
value: string
description: >
Optional. The etag for this logical view. This may be sent on update requests to ensure that the client has an up-to-date value before proceeding. The server returns an ABORTED error on a mismatched etag.
- name: deletionProtection
value: boolean
description: >
Optional. Set to true to make the LogicalView protected against deletion.
- name: logicalViewId
value: string
UPDATE
examples
- patch
Updates a logical view within an instance.
UPDATE google.bigtableadmin.logical_views
SET
data__name = '{{ name }}',
data__query = '{{ query }}',
data__etag = '{{ etag }}',
data__deletionProtection = {{ deletionProtection }}
WHERE
projectsId = '{{ projectsId }}' --required
AND instancesId = '{{ instancesId }}' --required
AND logicalViewsId = '{{ logicalViewsId }}' --required
AND updateMask = '{{ updateMask}}'
RETURNING
name,
done,
error,
metadata,
response;
DELETE
examples
- delete
Deletes a logical view from an instance.
DELETE FROM google.bigtableadmin.logical_views
WHERE projectsId = '{{ projectsId }}' --required
AND instancesId = '{{ instancesId }}' --required
AND logicalViewsId = '{{ logicalViewsId }}' --required
AND etag = '{{ etag }}';