Your e-commerce analytics team issues ad-hoc interactive queries against a 180-TB BigQuery table that stores 90 days of click-stream events. The project is billed with BigQuery's on-demand model, and daily query volume fluctuates, making long-term slot commitments unattractive. Analysts usually inspect only the most recent three days of data, but each query currently scans the full table, driving up costs. To lower query charges while continuing to use on-demand pricing, which approach should you implement?
Apply gzip compression to the existing table so the bytes scanned by each query are smaller.
Upgrade to BigQuery Enterprise Edition and buy a 500-slot reservation to run queries on flat-rate capacity.
Partition the table by date and require queries to include a filter on the partitioning column so only recent partitions are scanned.
Export the data to Cloud Storage and query it as a BigLake external table, eliminating per-query charges.
Under BigQuery's on-demand model you pay for the number of bytes each query reads. Converting the log table to a date-partitioned table (for example, partitioned by ingestion or event date) and having analysts filter on the partitioning column limits scanning to just the partitions that hold the last three days of data. Because the amount of data read drops from 180 TB to roughly 6 TB, the on-demand cost of every query falls proportionally. Purchasing slot reservations, exporting to external tables, or applying gzip compression would not cut on-demand query bytes in this scenario: flat-rate slots change the pricing model, external tables are still billed per bytes processed, and storage compression does not change how many logical bytes a query scans.
Ask Bash
Bash is our AI bot, trained to help you pass your exam. AI Generated Content may display inaccurate information, always double-check anything important.
Why is table partitioning effective for lowering query costs in BigQuery?
Open an interactive chat with Bash
What is the difference between on-demand pricing and flat-rate pricing in BigQuery?
Open an interactive chat with Bash
How does gzip compression affect BigQuery query costs?
Open an interactive chat with Bash
What is table partitioning in BigQuery?
Open an interactive chat with Bash
How is cost calculated under BigQuery's on-demand pricing model?
Open an interactive chat with Bash
What are the key differences between flat-rate and on-demand pricing in BigQuery?
Open an interactive chat with Bash
GCP Professional Data Engineer
Maintaining and automating data workloads
Your Score:
Report Issue
Bash, the Crucial Exams Chat Bot
AI Bot
Loading...
Loading...
Loading...
Pass with Confidence.
IT & Cybersecurity Package
You have hit the limits of our free tier, become a Premium Member today for unlimited access.
Military, Healthcare worker, Gov. employee or Teacher? See if you qualify for a Community Discount.
Monthly
$19.99 $11.99
$11.99/mo
Billed monthly, Cancel any time.
$19.99 after promotion ends
3 Month Pass
$44.99 $26.99
$8.99/mo
One time purchase of $26.99, Does not auto-renew.
$44.99 after promotion ends
Save $18!
MOST POPULAR
Annual Pass
$119.99 $71.99
$5.99/mo
One time purchase of $71.99, Does not auto-renew.
$119.99 after promotion ends
Save $48!
BEST DEAL
Lifetime Pass
$189.99 $113.99
One time purchase, Good for life.
Save $76!
What You Get
All IT & Cybersecurity Package plans include the following perks and exams .