# BigQueryPartition

Partitioning for a table Sheetgo creates.

Omit `field` for ingestion-time partitioning; name a column for
field-based. There is no third setting: BigQuery infers the partition
column's *type* from the table schema, so presence of `field` is the whole
distinction.

Only applied when the table is created. An existing table keeps its own
partitioning, so change it with `write_mode: "recreate"`.

Type: object

Fields typed as another model are documented on that model's page; fetch it before filling the field.

| Field | Type | Required | Description | Allowed values / default / constraints |
| --- | --- | --- | --- | --- |
| `field` | string, nullable | no | Column to partition by. It must exist in the transferred data -- check with `GET /rest/beta/bigquery/.../tables/{table}`. Omit for ingestion-time partitioning. |  |
| `granularity` | [BigQueryPartitionGranularity](https://dev-api.sheetgo.com/rest/reference/models/BigQueryPartitionGranularity.md) | no | Partition size: HOUR, DAY, MONTH or YEAR. | default: `"DAY"` |
| `require_filter` | boolean | no | Require queries against the table to filter on the partition column. Applied only when the table is created. | default: `false` |

## Used by

- [GET /rest/beta/automations/](https://dev-api.sheetgo.com/rest/reference/automations.md#get-rest-beta-automations)
- [GET /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#get-rest-beta-automations-id)
- [GET /rest/beta/workflows/](https://dev-api.sheetgo.com/rest/reference/workflows.md#get-rest-beta-workflows)
- [GET /rest/beta/workflows/{id}](https://dev-api.sheetgo.com/rest/reference/workflows.md#get-rest-beta-workflows-id)
- [PATCH /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#patch-rest-beta-automations-id)
- [PATCH /rest/beta/workflows/{id}](https://dev-api.sheetgo.com/rest/reference/workflows.md#patch-rest-beta-workflows-id)
- [POST /rest/beta/automations/](https://dev-api.sheetgo.com/rest/reference/automations.md#post-rest-beta-automations)
- [POST /rest/beta/workflows/](https://dev-api.sheetgo.com/rest/reference/workflows.md#post-rest-beta-workflows)
- [PUT /rest/beta/automations/{id}](https://dev-api.sheetgo.com/rest/reference/automations.md#put-rest-beta-automations-id)
- [DestinationBigQuery-Input](https://dev-api.sheetgo.com/rest/reference/models/DestinationBigQuery-Input.md)
- [DestinationBigQuery-Output](https://dev-api.sheetgo.com/rest/reference/models/DestinationBigQuery-Output.md)

---

More: start page https://dev-api.sheetgo.com/rest/reference.md, everything in one file https://dev-api.sheetgo.com/rest/llms-full.txt, OpenAPI https://dev-api.sheetgo.com/rest/openapi.json.
