Documentation Index
Fetch the complete documentation index at: https://support.detrics.io/llms.txt
Use this file to discover all available pages before exploring further.
Last updated: March 18, 2026
The Problem
Every marketing platform uses its own naming convention for fields:The Solution
Detrics normalizes all column names to snake_case before loading data into BigQuery. This means every platform’s fields follow the same convention, and you can write clean cross-platform SQL without worrying about naming differences.Normalization Rules
Detrics applies these rules in order:| Rule | Before | After |
|---|---|---|
| Dots become underscores | campaign.name | campaign_name |
| camelCase splits | campaignName | campaign_name |
| ALL_CAPS lowercased | CAMPAIGN_NAME | campaign_name |
| Acronyms lowered | CTR | ctr |
| Letter-digit boundaries | videoViewsP25 | video_views_p25 |
| Consecutive underscores collapsed | campaign__name | campaign_name |
| Leading/trailing underscores stripped | _campaign_name_ | campaign_name |
| Digit-leading names prefixed | 7day_click | _7day_click |
Examples
Before and After
| Platform | Original Field | BigQuery Column |
|---|---|---|
| Google Ads | campaign.name | campaign_name |
| Google Ads | metrics.cost_micros | metrics_cost_micros |
| Meta Ads | campaign_name | campaign_name |
| GA4 | sessionSourceMedium | session_source_medium |
| GA4 | totalUsers | total_users |
CAMPAIGN_NAME | campaign_name | |
TOTAL_IMPRESSION | total_impression | |
| Shopify | grossSales | gross_sales |
| Shopify | orderCount | order_count |
| TikTok | campaign_name | campaign_name |
| Meta Ads | offsite_conversion.fb_pixel_purchase | offsite_conversion_fb_pixel_purchase |
Cross-Platform SQL
With normalized column names, cross-platform queries become straightforward:System Columns
System columns added by Detrics always use the_detrics_ prefix and are already in snake_case:
_detrics_account_id_detrics_row_id_detrics_sync_id_detrics_synced_at
Type Mapping
In addition to name normalization, Detrics maps platform data types to BigQuery-native types:| Detrics Type | BigQuery Type |
|---|---|
| string | STRING |
| float, float64 | FLOAT64 |
| integer, int64 | INT64 |
| date | DATE |
| datetime | DATETIME |
| timestamp | TIMESTAMP |
| boolean | BOOL |
| percent | FLOAT64 |
| currency | FLOAT64 |
| number | FLOAT64 |