MySQL HeatWave is a fully managed cloud database service that integrates with MySQL, combining transactions, analytics, machine learning, and generative AI capabilities. It features an in-memory query accelerator for real-time analytics, eliminating the need for ETL processes to separate databases. Available on Oracle Cloud Infrastructure (OCI), AWS, and Azure, HeatWave automates tasks like backups and patching, offering high performance, scalability, and security for OLTP and OLAP workloads.
Modern applications demand real-time insights to power live dashboards, customer-facing reports, or operational analytics from ever-growing data. Traditional approaches often rely on complex ETL pipelines or manual refresh logic to keep analytics current. MySQL HeatWave addresses this challenge with a completely new feature for MySQL: Auto-Refresh Materialized Views—enabling fast, simplified, and always-up-to-date analytics at scale.
A First for MySQL: Materialized Views with Auto-Refresh
MySQL supports views which enable better data management, simpler queries, and more efficient security practices. However, traditional views in MySQL logical: they save the query definition, but every query execution must recompute the results. This works for small or simple queries, but becomes a bottleneck for complex analytical queries.
HeatWave Auto-Refresh Materialized Views change that. These views store precomputed query results directly in HeatWave’s in-memory engine, providing significant performance gains. Unlike traditional materialized views that require manual refreshes or scheduled jobs, HeatWave automatically updates the views whenever the underlying data changes—offering a seamless, zero-maintenance solution for real-time analytics.
Real-Time Dashboards Made Simple
MySQL HeatWave already delivers real-time analytics through its tight integration with MySQL. When data changes in the database, it’s automatically updated in HeatWave memory. This keeps analytical queries fresh without the need for ETL or data replication, eliminates latency and ensures consistency between operational and analytical workloads.
With the introduction of auto-refresh materialized views, HeatWave takes real-time analytics even further. Instead of recalculating complex joins or aggregations repeatedly, you materialize those results once in memory, and HeatWave keeps them up to date automatically. This greatly reduces compute load, optimizes resource usage, and improves performance and scalability, especially for high-concurrency scenarios like dashboards and reporting systems.
Whether you’re building customer-facing dashboards, executive KPIs, or real-time monitoring solutions, HeatWave ensures your data is always fresh.
When Should You Use Auto-Refresh Materialized Views?
Materialized views are most impactful for complex queries that are reused frequently. Some ideal use cases include:
- Repeated joins across large fact and dimension tables, such as in sales, inventory, or customer analytics.
- Nested subqueries that appear across multiple reports or applications.
- Complex aggregations used in dashboards or machine learning pipelines—for example, customer segmentation or churn prediction.
By caching the results of these operations in memory and automatically refreshing them, HeatWave executes heavy queries once, delivering significant gains in speed, efficiency, and cost-effectiveness.
Boost Performance, Lower Load
MySQL HeatWave already offers industry-leading performance and price-performance for analytics and mixed workloads through its in-memory, massively parallel execution engine. But even in a high-performance system, repeatedly evaluating the same complex queries (e.g., multi-table joins or aggregations) can introduce unnecessary overhead—especially when those queries are used in dashboards, reports, or recurring processes.
With auto-refresh materialized views:
- Heavy computations are executed once and stored in memory.
- Future queries access results instantly.
- Query latency drops.
- System resources are freed up for other workloads.
This leads to faster insights, improved scalability for concurrent users, and lower infrastructure costs.
Secure and Scalable for Enterprise Workloads
HeatWave materialized views support MySQL’s role-based access control, allowing secure, isolated access to data views. Business teams can explore data independently while maintaining centralized governance. Combined with HeatWave’s massively parallel architecture, you get enterprise-grade security, speed, and scalability without needing a separate analytics database or data warehouse.
How It Works: Auto-refresh Materialized Views
HeatWave Auto-Refresh Materialized Views work by caching expensive query results directly in memory. Here’s how:
- Joins, subqueries, and aggregations are computed once and reused.
- Re-materialization happens automatically when base tables change, no manual steps or scheduling required.
- If a materialized view can’t be used, HeatWave automatically falls back to logical view behavior, with no changes required to application code.
Creating Materialized Views
Using MySQL’s familiar syntax, materialized views are easy to define:
CREATE MATERIALIZED VIEW customer_orders AS
SELECT c.customer_id, o.order_id, o.order_date, o.amount
FROM customers c
JOIN orders o ON c.customer_id = o.customer_id;
Existing views can also be converted with a simple ALTER statement:
ALTER MATERIALIZED VIEW customer_orders AS
SELECT ...;
Developers and DBAs can monitor it via performance_schema, which includes details like the original MATERIALIZATION_QUERY.
Example: Loyalty Metrics Use Case
Let’s say you want to compute customer loyalty by counting the number of orders per customer.
Without Materialized View (Standard View)
Every query recomputes the same join:
SELECT c.customer_id, COUNT(o.order_id) AS order_count
FROM (
SELECT c.customer_id, o.order_id, o.order_date, o.amount
FROM customers c
JOIN orders o ON c.customer_id = o.customer_id
) AS v
GROUP BY c.customer_id;
- Join is repeated for every query.
- Adds latency and resource consumption.
With HeatWave Materialized View
Precompute the join once, and reuse it:
-- Materialize the join once
CREATE MATERIALIZED VIEW customer_orders AS
SELECT c.customer_id, o.order_id, o.order_date, o.amount
FROM customers c
JOIN orders o ON c.customer_id = o.customer_id;
-- Reuse the result in multiple queries
SELECT customer_id, COUNT(order_id) AS order_count
FROM customer_orders
GROUP BY customer_id;
- The expensive join is cached in memory.
- Subsequent queries are faster and cheaper.
- Changes in the base tables automatically trigger refreshes.
This pattern works well for dashboards, scheduled reports, and machine learning feature pipelines where query logic is reused but the underlying data continues to evolve.
Summary
MySQL HeatWave Auto-Refresh Materialized Views introduce a completely new capability to MySQL, bridging the gap between transactional systems and real-time analytics. With automatic updates, significant performance improvements, no changes to existing applications and seamless integration into existing MySQL workflows, this feature simplifies how organizations deliver fast, reliable insights at scale. Whether you’re building dashboards, reports, or intelligent applications, MySQL HeatWave helps you stay real-time, resource-efficient, and developer-friendly.

