Google Cloud Platform (GCP)
Core Compute Services
Storage & Databases
- Google Cloud Storage
- Persistent Disks
- Cloud Filestore
- Cloud SQL
- Cloud Spanner
- Cloud Bigtable
- Cloud Firestore
Data Analytics & AI
Google Cloud Platform
BigQuery Multi-Statement Queries Example
 
main.sql
  -- Multi-Statement Queries Example
  -- Create a Temporary Table
  CREATE OR REPLACE TEMPORARY TABLE temp_table AS
  SELECT *
  FROM `your_project_id.your_dataset.your_source_table`
  WHERE date > '2023-01-01';
  -- Perform Aggregation
  SELECT
    DATE_TRUNC(DATE(date), MONTH) AS month,
    COUNT(*) AS total_records
  FROM temp_table
  GROUP BY month
  ORDER BY month;