-
Notifications
You must be signed in to change notification settings - Fork 10k
DS-15647 DS-15648: Document aggregate-if and date/time function additions to the WAE SQL API #26101
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
Merged
rianvdm
merged 4 commits into
cloudflare:production
from
46bit:miki/sql-api-for-analytics-date-time-functions
Nov 12, 2025
+439
−21
Merged
Changes from 3 commits
Commits
Show all changes
4 commits
Select commit
Hold shift + click to select a range
969568f
DS-15647 DS-15648: Document aggregate-if and date/time function addit…
46bit 0288f51
DS-15648: Document further date/time function additions to the WAE SQ…
46bit 7e4515c
Add changelog for further WAE SQL additions
46bit c97331e
Update src/content/changelog/workers/2025-11-12-analytics-engine-furt…
46bit File filter
Filter by extension
Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
There are no files selected for viewing
40 changes: 40 additions & 0 deletions
40
...tent/changelog/workers/2025-11-12-analytics-engine-further-sql-enhancements.mdx
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
| Original file line number | Diff line number | Diff line change |
|---|---|---|
| @@ -0,0 +1,40 @@ | ||
| --- | ||
| title: Workers Analytics Engine expands SQL support further | ||
| description: Workers Analytics Engine now supports more SQL functions for aggregation and for working with dates and times | ||
| date: 2025-11-12 | ||
| products: | ||
| - workers-analytics-engine | ||
| --- | ||
| You can now perform more powerful queries directly in [Workers Analytics Engine](https://developers.cloudflare.com/analytics/analytics-engine/) with a major expansion of our SQL function library. | ||
|
|
||
| Workers Analytics Engine allows you to ingest and store high-cardinality data at scale (such as custom analytics) and query your data through a simple SQL API. | ||
|
|
||
| Today, we've expanded Workers Analytics Engine's SQL capabilities with several new functions: | ||
|
|
||
| [**New aggregate functions:**](https://developers.cloudflare.com/analytics/analytics-engine/sql-reference/aggregate-functions/) | ||
| - `countIf()` - count the number of rows which satisfy a provided condition | ||
| - `sumIf()` - calculate a sum from rows which satisfy a provided condition | ||
| - `avgIf()` - calculate an average from rows which satisfy a provided condition | ||
|
|
||
| [**New date and time functions:**](https://developers.cloudflare.com/analytics/analytics-engine/sql-reference/date-time-functions/) | ||
| - `toYear()` | ||
| - `toMonth()` | ||
| - `toDayOfMonth()` | ||
| - `toDayOfWeek()` | ||
| - `toHour()` | ||
| - `toMinute()` | ||
| - `toSecond()` | ||
| - `toStartOfYear()` | ||
| - `toStartOfMonth()` | ||
| - `toStartOfWeek()` | ||
| - `toStartOfDay()` | ||
| - `toStartOfHour()` | ||
| - `toStartOfFifteenMinutes()` | ||
| - `toStartOfTenMinutes()` | ||
| - `toStartOfFiveMinutes()` | ||
| - `toStartOfMinute()` | ||
| - `today()` | ||
| - `toYYYYMM()` | ||
|
|
||
| ## Ready to get started? | ||
| Whether you're building usage-based billing systems, customer analytics dashboards, or other custom analytics, these functions let you get the most out of your data. [Get started ](/analytics/analytics-engine/get-started/) with Workers Analytics Engine and explore all available functions in our [SQL reference documentation](/analytics/analytics-engine/sql-reference/). | ||
This file contains hidden or bidirectional Unicode text that may be interpreted or compiled differently than what appears below. To review, open the file in an editor that reveals hidden Unicode characters.
Learn more about bidirectional Unicode characters
Oops, something went wrong.
Add this suggestion to a batch that can be applied as a single commit.
This suggestion is invalid because no changes were made to the code.
Suggestions cannot be applied while the pull request is closed.
Suggestions cannot be applied while viewing a subset of changes.
Only one suggestion per line can be applied in a batch.
Add this suggestion to a batch that can be applied as a single commit.
Applying suggestions on deleted lines is not supported.
You must change the existing code in this line in order to create a valid suggestion.
Outdated suggestions cannot be applied.
This suggestion has been applied or marked resolved.
Suggestions cannot be applied from pending reviews.
Suggestions cannot be applied on multi-line comments.
Suggestions cannot be applied while the pull request is queued to merge.
Suggestion cannot be applied right now. Please check back later.
Uh oh!
There was an error while loading. Please reload this page.