Skip to main content
Skip table of contents

STORAGE.REQUIRE_PARTITION_FILTER

Target database: Google BigQuery

STORAGE.REQUIRE_PARTITION_FILTER option updates the selected partitioned table queries to require partition filter.


Target DMBS

Entity types

Feature

Google BigQuery

TABLE

When set true, every query on that table must include at least one predicate that only references the partitioning column


See also:


Usage

CODE
STORAGE.REQUIRE_PARTITION_FILTER: true

Notes

Check Export SQL/Entity SQL after defining a PARTITION_KEY to see generated DDL.

Google BigQuery

Can be used with partitioned tables, created either through DISTRIBUTION_KEY or PARTITION_SCHEME.

Examples

Google BigQuery partitioned table having partition filter required

Key definition:

DEFINITION
KEY NAME: F_TRIP
KEY TYPE: PARTITION_KEY
ATTRIBUTE NAME: category

Physical option definitions:

DEFINITION
Physical option name: STORAGE.PARTITION_SCHEME
Physical option value: RANGE_BUCKET(<entity_partition_key>, GENERATE_ARRAY(0, 1000, 200))

Physical option name: STORAGE.REQUIRE_PARTITION_FILTER
Physical option value: true

DDL generated by Agile Data Engine:

SQL
CREATE TABLE pub.F_TRIP
(
  ...
)
PARTITION BY RANGE_BUCKET(category, GENERATE_ARRAY(0, 1000, 200))
OPTIONS (
    require_partition_filter = true
);
JavaScript errors detected

Please note, these errors can depend on your browser setup.

If this problem persists, please contact our support.