1<html><body> 2<style> 3 4body, h1, h2, h3, div, span, p, pre, a { 5 margin: 0; 6 padding: 0; 7 border: 0; 8 font-weight: inherit; 9 font-style: inherit; 10 font-size: 100%; 11 font-family: inherit; 12 vertical-align: baseline; 13} 14 15body { 16 font-size: 13px; 17 padding: 1em; 18} 19 20h1 { 21 font-size: 26px; 22 margin-bottom: 1em; 23} 24 25h2 { 26 font-size: 24px; 27 margin-bottom: 1em; 28} 29 30h3 { 31 font-size: 20px; 32 margin-bottom: 1em; 33 margin-top: 1em; 34} 35 36pre, code { 37 line-height: 1.5; 38 font-family: Monaco, 'DejaVu Sans Mono', 'Bitstream Vera Sans Mono', 'Lucida Console', monospace; 39} 40 41pre { 42 margin-top: 0.5em; 43} 44 45h1, h2, h3, p { 46 font-family: Arial, sans serif; 47} 48 49h1, h2, h3 { 50 border-bottom: solid #CCC 1px; 51} 52 53.toc_element { 54 margin-top: 0.5em; 55} 56 57.firstline { 58 margin-left: 2 em; 59} 60 61.method { 62 margin-top: 1em; 63 border: solid 1px #CCC; 64 padding: 1em; 65 background: #EEE; 66} 67 68.details { 69 font-weight: bold; 70 font-size: 14px; 71} 72 73</style> 74 75<h1><a href="bigquery_v2.html">BigQuery API</a> . <a href="bigquery_v2.datasets.html">datasets</a></h1> 76<h2>Instance Methods</h2> 77<p class="toc_element"> 78 <code><a href="#delete">delete(projectId, datasetId, deleteContents=None)</a></code></p> 79<p class="firstline">Deletes the dataset specified by the datasetId value. Before you can delete a dataset, you must delete all its tables, either manually or by specifying deleteContents. Immediately after deletion, you can create another dataset with the same name.</p> 80<p class="toc_element"> 81 <code><a href="#get">get(projectId, datasetId)</a></code></p> 82<p class="firstline">Returns the dataset specified by datasetID.</p> 83<p class="toc_element"> 84 <code><a href="#insert">insert(projectId, body)</a></code></p> 85<p class="firstline">Creates a new empty dataset.</p> 86<p class="toc_element"> 87 <code><a href="#list">list(projectId, filter=None, all=None, pageToken=None, maxResults=None)</a></code></p> 88<p class="firstline">Lists all datasets in the specified project to which you have been granted the READER dataset role.</p> 89<p class="toc_element"> 90 <code><a href="#list_next">list_next(previous_request, previous_response)</a></code></p> 91<p class="firstline">Retrieves the next page of results.</p> 92<p class="toc_element"> 93 <code><a href="#patch">patch(projectId, datasetId, body)</a></code></p> 94<p class="firstline">Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource. This method supports patch semantics.</p> 95<p class="toc_element"> 96 <code><a href="#update">update(projectId, datasetId, body)</a></code></p> 97<p class="firstline">Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource.</p> 98<h3>Method Details</h3> 99<div class="method"> 100 <code class="details" id="delete">delete(projectId, datasetId, deleteContents=None)</code> 101 <pre>Deletes the dataset specified by the datasetId value. Before you can delete a dataset, you must delete all its tables, either manually or by specifying deleteContents. Immediately after deletion, you can create another dataset with the same name. 102 103Args: 104 projectId: string, Project ID of the dataset being deleted (required) 105 datasetId: string, Dataset ID of dataset being deleted (required) 106 deleteContents: boolean, If True, delete all the tables in the dataset. If False and the dataset contains tables, the request will fail. Default is False 107</pre> 108</div> 109 110<div class="method"> 111 <code class="details" id="get">get(projectId, datasetId)</code> 112 <pre>Returns the dataset specified by datasetID. 113 114Args: 115 projectId: string, Project ID of the requested dataset (required) 116 datasetId: string, Dataset ID of the requested dataset (required) 117 118Returns: 119 An object of the form: 120 121 { 122 "kind": "bigquery#dataset", # [Output-only] The resource type. 123 "description": "A String", # [Optional] A user-friendly description of the dataset. 124 "datasetReference": { # [Required] A reference that identifies the dataset. 125 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 126 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 127 }, 128 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 129 "a_key": "A String", 130 }, 131 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 132 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 133 { 134 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 135 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 136 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 137 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 138 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 139 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 140 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 141 "projectId": "A String", # [Required] The ID of the project containing this table. 142 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 143 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 144 }, 145 }, 146 ], 147 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 148 "etag": "A String", # [Output-only] A hash of the resource. 149 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 150 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 151 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 152 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 153 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 154 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 155 }</pre> 156</div> 157 158<div class="method"> 159 <code class="details" id="insert">insert(projectId, body)</code> 160 <pre>Creates a new empty dataset. 161 162Args: 163 projectId: string, Project ID of the new dataset (required) 164 body: object, The request body. (required) 165 The object takes the form of: 166 167{ 168 "kind": "bigquery#dataset", # [Output-only] The resource type. 169 "description": "A String", # [Optional] A user-friendly description of the dataset. 170 "datasetReference": { # [Required] A reference that identifies the dataset. 171 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 172 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 173 }, 174 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 175 "a_key": "A String", 176 }, 177 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 178 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 179 { 180 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 181 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 182 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 183 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 184 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 185 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 186 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 187 "projectId": "A String", # [Required] The ID of the project containing this table. 188 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 189 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 190 }, 191 }, 192 ], 193 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 194 "etag": "A String", # [Output-only] A hash of the resource. 195 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 196 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 197 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 198 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 199 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 200 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 201 } 202 203 204Returns: 205 An object of the form: 206 207 { 208 "kind": "bigquery#dataset", # [Output-only] The resource type. 209 "description": "A String", # [Optional] A user-friendly description of the dataset. 210 "datasetReference": { # [Required] A reference that identifies the dataset. 211 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 212 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 213 }, 214 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 215 "a_key": "A String", 216 }, 217 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 218 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 219 { 220 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 221 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 222 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 223 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 224 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 225 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 226 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 227 "projectId": "A String", # [Required] The ID of the project containing this table. 228 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 229 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 230 }, 231 }, 232 ], 233 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 234 "etag": "A String", # [Output-only] A hash of the resource. 235 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 236 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 237 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 238 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 239 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 240 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 241 }</pre> 242</div> 243 244<div class="method"> 245 <code class="details" id="list">list(projectId, filter=None, all=None, pageToken=None, maxResults=None)</code> 246 <pre>Lists all datasets in the specified project to which you have been granted the READER dataset role. 247 248Args: 249 projectId: string, Project ID of the datasets to be listed (required) 250 filter: string, An expression for filtering the results of the request by label. The syntax is "labels.<name>[:<value>]". Multiple filters can be ANDed together by connecting with a space. Example: "labels.department:receiving labels.active". See Filtering datasets using labels for details. 251 all: boolean, Whether to list all datasets, including hidden ones 252 pageToken: string, Page token, returned by a previous call, to request the next page of results 253 maxResults: integer, The maximum number of results to return 254 255Returns: 256 An object of the form: 257 258 { 259 "nextPageToken": "A String", # A token that can be used to request the next results page. This property is omitted on the final results page. 260 "kind": "bigquery#datasetList", # The list type. This property always returns the value "bigquery#datasetList". 261 "datasets": [ # An array of the dataset resources in the project. Each resource contains basic information. For full information about a particular dataset resource, use the Datasets: get method. This property is omitted when there are no datasets in the project. 262 { 263 "kind": "bigquery#dataset", # The resource type. This property always returns the value "bigquery#dataset". 264 "datasetReference": { # The dataset reference. Use this property to access specific parts of the dataset's ID, such as project ID or dataset ID. 265 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 266 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 267 }, 268 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. 269 "a_key": "A String", 270 }, 271 "location": "A String", # The geographic location where the data resides. 272 "friendlyName": "A String", # A descriptive name for the dataset, if one exists. 273 "id": "A String", # The fully-qualified, unique, opaque ID of the dataset. 274 }, 275 ], 276 "etag": "A String", # A hash value of the results page. You can use this property to determine if the page has changed since the last request. 277 }</pre> 278</div> 279 280<div class="method"> 281 <code class="details" id="list_next">list_next(previous_request, previous_response)</code> 282 <pre>Retrieves the next page of results. 283 284Args: 285 previous_request: The request for the previous page. (required) 286 previous_response: The response from the request for the previous page. (required) 287 288Returns: 289 A request object that you can call 'execute()' on to request the next 290 page. Returns None if there are no more items in the collection. 291 </pre> 292</div> 293 294<div class="method"> 295 <code class="details" id="patch">patch(projectId, datasetId, body)</code> 296 <pre>Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource. This method supports patch semantics. 297 298Args: 299 projectId: string, Project ID of the dataset being updated (required) 300 datasetId: string, Dataset ID of the dataset being updated (required) 301 body: object, The request body. (required) 302 The object takes the form of: 303 304{ 305 "kind": "bigquery#dataset", # [Output-only] The resource type. 306 "description": "A String", # [Optional] A user-friendly description of the dataset. 307 "datasetReference": { # [Required] A reference that identifies the dataset. 308 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 309 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 310 }, 311 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 312 "a_key": "A String", 313 }, 314 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 315 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 316 { 317 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 318 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 319 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 320 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 321 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 322 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 323 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 324 "projectId": "A String", # [Required] The ID of the project containing this table. 325 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 326 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 327 }, 328 }, 329 ], 330 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 331 "etag": "A String", # [Output-only] A hash of the resource. 332 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 333 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 334 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 335 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 336 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 337 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 338 } 339 340 341Returns: 342 An object of the form: 343 344 { 345 "kind": "bigquery#dataset", # [Output-only] The resource type. 346 "description": "A String", # [Optional] A user-friendly description of the dataset. 347 "datasetReference": { # [Required] A reference that identifies the dataset. 348 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 349 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 350 }, 351 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 352 "a_key": "A String", 353 }, 354 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 355 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 356 { 357 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 358 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 359 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 360 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 361 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 362 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 363 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 364 "projectId": "A String", # [Required] The ID of the project containing this table. 365 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 366 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 367 }, 368 }, 369 ], 370 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 371 "etag": "A String", # [Output-only] A hash of the resource. 372 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 373 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 374 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 375 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 376 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 377 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 378 }</pre> 379</div> 380 381<div class="method"> 382 <code class="details" id="update">update(projectId, datasetId, body)</code> 383 <pre>Updates information in an existing dataset. The update method replaces the entire dataset resource, whereas the patch method only replaces fields that are provided in the submitted dataset resource. 384 385Args: 386 projectId: string, Project ID of the dataset being updated (required) 387 datasetId: string, Dataset ID of the dataset being updated (required) 388 body: object, The request body. (required) 389 The object takes the form of: 390 391{ 392 "kind": "bigquery#dataset", # [Output-only] The resource type. 393 "description": "A String", # [Optional] A user-friendly description of the dataset. 394 "datasetReference": { # [Required] A reference that identifies the dataset. 395 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 396 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 397 }, 398 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 399 "a_key": "A String", 400 }, 401 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 402 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 403 { 404 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 405 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 406 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 407 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 408 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 409 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 410 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 411 "projectId": "A String", # [Required] The ID of the project containing this table. 412 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 413 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 414 }, 415 }, 416 ], 417 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 418 "etag": "A String", # [Output-only] A hash of the resource. 419 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 420 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 421 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 422 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 423 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 424 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 425 } 426 427 428Returns: 429 An object of the form: 430 431 { 432 "kind": "bigquery#dataset", # [Output-only] The resource type. 433 "description": "A String", # [Optional] A user-friendly description of the dataset. 434 "datasetReference": { # [Required] A reference that identifies the dataset. 435 "projectId": "A String", # [Optional] The ID of the project containing this dataset. 436 "datasetId": "A String", # [Required] A unique ID for this dataset, without the project name. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 437 }, 438 "labels": { # The labels associated with this dataset. You can use these to organize and group your datasets. You can set this property when inserting or updating a dataset. See Creating and Updating Dataset Labels for more information. 439 "a_key": "A String", 440 }, 441 "creationTime": "A String", # [Output-only] The time when this dataset was created, in milliseconds since the epoch. 442 "access": [ # [Optional] An array of objects that define dataset access for one or more entities. You can set this property when inserting or updating a dataset in order to control who is allowed to access the data. If unspecified at dataset creation time, BigQuery adds default dataset access for the following entities: access.specialGroup: projectReaders; access.role: READER; access.specialGroup: projectWriters; access.role: WRITER; access.specialGroup: projectOwners; access.role: OWNER; access.userByEmail: [dataset creator email]; access.role: OWNER; 443 { 444 "domain": "A String", # [Pick one] A domain to grant access to. Any users signed in with the domain specified will be granted the specified access. Example: "example.com". Maps to IAM policy member "domain:DOMAIN". 445 "userByEmail": "A String", # [Pick one] An email address of a user to grant access to. For example: fred@example.com. Maps to IAM policy member "user:EMAIL" or "serviceAccount:EMAIL". 446 "specialGroup": "A String", # [Pick one] A special group to grant access to. Possible values include: projectOwners: Owners of the enclosing project. projectReaders: Readers of the enclosing project. projectWriters: Writers of the enclosing project. allAuthenticatedUsers: All authenticated BigQuery users. Maps to similarly-named IAM members. 447 "groupByEmail": "A String", # [Pick one] An email address of a Google Group to grant access to. Maps to IAM policy member "group:GROUP". 448 "role": "A String", # [Required] An IAM role ID that should be granted to the user, group, or domain specified in this access entry. The following legacy mappings will be applied: OWNER roles/bigquery.dataOwner WRITER roles/bigquery.dataEditor READER roles/bigquery.dataViewer This field will accept any of the above formats, but will return only the legacy format. For example, if you set this field to "roles/bigquery.dataOwner", it will be returned back as "OWNER". 449 "iamMember": "A String", # [Pick one] Some other type of member that appears in the IAM Policy but isn't a user, group, domain, or special group. 450 "view": { # [Pick one] A view from a different dataset to grant access to. Queries executed against that view will have read access to tables in this dataset. The role field is not required when this field is set. If that view is updated by any user, access to the view needs to be granted again via an update operation. 451 "projectId": "A String", # [Required] The ID of the project containing this table. 452 "tableId": "A String", # [Required] The ID of the table. The ID must contain only letters (a-z, A-Z), numbers (0-9), or underscores (_). The maximum length is 1,024 characters. 453 "datasetId": "A String", # [Required] The ID of the dataset containing this table. 454 }, 455 }, 456 ], 457 "defaultTableExpirationMs": "A String", # [Optional] The default lifetime of all tables in the dataset, in milliseconds. The minimum value is 3600000 milliseconds (one hour). Once this property is set, all newly-created tables in the dataset will have an expirationTime property set to the creation time plus the value in this property, and changing the value will only affect new tables, not existing ones. When the expirationTime for a given table is reached, that table will be deleted automatically. If a table's expirationTime is modified or removed before the table expires, or if you provide an explicit expirationTime when creating a table, that value takes precedence over the default expiration time indicated by this property. 458 "etag": "A String", # [Output-only] A hash of the resource. 459 "defaultPartitionExpirationMs": "A String", # [Optional] The default partition expiration for all partitioned tables in the dataset, in milliseconds. Once this property is set, all newly-created partitioned tables in the dataset will have an expirationMs property in the timePartitioning settings set to this value, and changing the value will only affect new tables, not existing ones. The storage in a partition will have an expiration time of its partition time plus this value. Setting this property overrides the use of defaultTableExpirationMs for partitioned tables: only one of defaultTableExpirationMs and defaultPartitionExpirationMs will be used for any new partitioned table. If you provide an explicit timePartitioning.expirationMs when creating or updating a partitioned table, that value takes precedence over the default partition expiration time indicated by this property. 460 "location": "A String", # The geographic location where the dataset should reside. The default value is US. See details at https://cloud.google.com/bigquery/docs/locations. 461 "friendlyName": "A String", # [Optional] A descriptive name for the dataset. 462 "lastModifiedTime": "A String", # [Output-only] The date when this dataset or any of its tables was last modified, in milliseconds since the epoch. 463 "id": "A String", # [Output-only] The fully-qualified unique name of the dataset in the format projectId:datasetId. The dataset name without the project name is given in the datasetId field. When creating a new dataset, leave this field blank, and instead specify the datasetId field. 464 "selfLink": "A String", # [Output-only] A URL that can be used to access the resource again. You can use this URL in Get or Update requests to the resource. 465 }</pre> 466</div> 467 468</body></html>