A materialized view is a duplicate data table created by combining data from multiple existing tables for faster data retrieval. For example, consider a retail application with two base tables for customer and product data. The customer table contains information like the customer’s name and contact details, while the product table contains information about product details and cost. The customer table only stores the product IDs of the items an individual customer purchases. You have to cross-reference both tables to obtain product details of items purchased by specific customers. Instead, you can create a materialized view that stores customer names and the associated product details in a single temporary table. You can build index structures on the materialized view for improved data read performance.","sortDate":"2023-08-09","headlineUrl":"https://aws.amazon.com/what-is/materialized-view/?trk=faq_card","id":"faq-hub#what-is-a-materialized-view","category":"Databases","primaryCTA":"https://portal.aws.amazon.com/gp/aws/developer/registration/index.html?pg=what_is_header","headline":"What is a Materialized View?"},"metadata":{"tags":[{"id":"GLOBAL#tech-category#databases","name":"Databases","namespaceId":"GLOBAL#tech-category","description":"Databases","metadata":{}}]}}]},"metadata":{"auth":{},"testAttributes":{}},"context":{"page":{"pageUrl":"https://aws.amazon.com/what-is/materialized-view/"},"environment":{"stage":"prod","region":"us-east-1"},"sdkVersion":"1.0.129"},"refMap":{"manifest.js":"289765ed09","what-is-header.js":"2e0d22c000","what-is-header.rtl.css":"ccf4035484","what-is-header.css":"ce47058367","what-is-header.css.js":"004a4704e8","what-is-header.rtl.css.js":"f687973e4f"},"settings":{"templateMappings":{"category":"category","headline":"headline","primaryCTA":"primaryCTA","primaryCTAText":"primaryCTAText","primaryBreadcrumbText":"primaryBreadcrumbText","primaryBreadcrumbURL":"primaryBreadcrumbURL"}}}
A materialized view is a duplicate data table created by combining data from multiple existing tables for faster data retrieval. For example, consider a retail application with two base tables for customer and product data. The customer table contains information like the customer’s name and contact details, while the product table contains information about product details and cost. The customer table only stores the product IDs of the items an individual customer purchases. You have to cross-reference both tables to obtain product details of items purchased by specific customers. Instead, you can create a materialized view that stores customer names and the associated product details in a single temporary table. You can build index structures on the materialized view for improved data read performance.","id":"seo-faq-pairs#what-is-a-materialized-view","customSort":"1"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"What are the benefits of materialized views?","faqAnswer":"
Materialized views are a fast and efficient method of accessing relevant data. They help with query optimization in data-intensive applications. We go through some of the major benefits next. \n
Speed \nRead queries scan through different tables and rows of data to gather the necessary information. With materialized views, you can query data directly from your new view instead of having to compute new information every time. The more complex your query is, the more time you will save using a materialized view. \n
Data storage simplicity \nMaterialized views allow you to consolidate complex query logic in one table. This makes data transformations and code maintenance easier for developers. It can also help make complex queries more manageable. You can also use data subsetting to decrease the amount of data you need to replicate in the view. \n
Consistency \nMaterialized views provide a consistent view of data captured at a specific moment. You can configure read consistency in materialized views and make data accessible even in multi-user environments where concurrency control is essential. \n
Materialized views also provide data access even if the source data changes or is deleted. Over time, this means that you can use materialized views to report on time-based data snapshots. The level of isolation from source tables ensures that you have a greater degree of consistency across your data. \n
Improved access control \nYou can use a materialized view to control who has access to specific data. You can filter information for users without giving them access to the source tables. This approach is practical if you want to control who has access to what data and how much of it they can see and interact with.","id":"seo-faq-pairs#what-are-the-benefits-of-materialized-views","customSort":"2"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"What are the use cases of materialized views?","faqAnswer":"
You can benefit from materialized views in many different scenarios. \n
Distribute filtered data \nIf you need to distribute recent data across many locations, like for a remote workforce, materialized views help. You replicate and distribute data to many sites using materialized views. The people needing access to data interact with the replicated data store closest to them geographically. \n
This system allows for concurrency and decreases network load. It’s an effective approach with read-only databases. \n
Analyze time series data \nMaterialized views provide timestamped snapshots of datasets, so you can model information changes over time. You can store precomputed aggregations of data, like monthly or weekly summaries. These uses are helpful for business intelligence and reporting platforms. \n
Remote data interaction \nIn distributed database systems, you can use materialized views to optimize queries involving data from remote servers. Rather than repeatedly fetching data from a remote source, you can fetch and store data in a local materialized view. This reduces the need for network communication and improving performance. \n
For example, if you receive data from an external database or through an API, a materialized view consolidates and helps process it. \n
Periodic batch processing \nMaterialized views are helpful for situations where periodic batch processing is required. For instance, a financial institution might use materialized views to store end-of-day balances and interest calculations. Or they might store portfolio performance summaries, which can be refreshed at the end of each business day.","id":"seo-faq-pairs#what-are-the-use-cases-of-materialized-views","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"How do materialized views work?","faqAnswer":"
Materialized views work by precomputing and storing the results of a specific query as a physical table in the database. The database performs the precomputation at regular intervals, or users can trigger it by specific events. Administrators monitor the performance and resource utilization of materialized views to ensure they continue to meet their intended purpose. \n
Here's a general overview of how materialized views work. \n
Create materialized view \nYou define a query that retrieves the desired data from one or more source tables for creating materialized views. This query may include filtering, aggregations, joins, and other operations as needed. \n
The database initially populates the materialized view by running the defined query against the source data. The result of the query is stored as a physical table in the database, and this table represents the materialized view. \n
Update materialized view \nThe data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
Materialized views allow you to consolidate complex query logic in one table. This makes data transformations and code maintenance easier for developers. It can also help make complex queries more manageable. You can also use data subsetting to decrease the amount of data you need to replicate in the view. \n
Consistency \nMaterialized views provide a consistent view of data captured at a specific moment. You can configure read consistency in materialized views and make data accessible even in multi-user environments where concurrency control is essential. \n
Materialized views also provide data access even if the source data changes or is deleted. Over time, this means that you can use materialized views to report on time-based data snapshots. The level of isolation from source tables ensures that you have a greater degree of consistency across your data. \n
Improved access control \nYou can use a materialized view to control who has access to specific data. You can filter information for users without giving them access to the source tables. This approach is practical if you want to control who has access to what data and how much of it they can see and interact with.","id":"seo-faq-pairs#what-are-the-benefits-of-materialized-views","customSort":"2"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"What are the use cases of materialized views?","faqAnswer":"
You can benefit from materialized views in many different scenarios. \n
Distribute filtered data \nIf you need to distribute recent data across many locations, like for a remote workforce, materialized views help. You replicate and distribute data to many sites using materialized views. The people needing access to data interact with the replicated data store closest to them geographically. \n
This system allows for concurrency and decreases network load. It’s an effective approach with read-only databases. \n
Analyze time series data \nMaterialized views provide timestamped snapshots of datasets, so you can model information changes over time. You can store precomputed aggregations of data, like monthly or weekly summaries. These uses are helpful for business intelligence and reporting platforms. \n
Remote data interaction \nIn distributed database systems, you can use materialized views to optimize queries involving data from remote servers. Rather than repeatedly fetching data from a remote source, you can fetch and store data in a local materialized view. This reduces the need for network communication and improving performance. \n
For example, if you receive data from an external database or through an API, a materialized view consolidates and helps process it. \n
Periodic batch processing \nMaterialized views are helpful for situations where periodic batch processing is required. For instance, a financial institution might use materialized views to store end-of-day balances and interest calculations. Or they might store portfolio performance summaries, which can be refreshed at the end of each business day.","id":"seo-faq-pairs#what-are-the-use-cases-of-materialized-views","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"How do materialized views work?","faqAnswer":"
Materialized views work by precomputing and storing the results of a specific query as a physical table in the database. The database performs the precomputation at regular intervals, or users can trigger it by specific events. Administrators monitor the performance and resource utilization of materialized views to ensure they continue to meet their intended purpose. \n
Here's a general overview of how materialized views work. \n
Create materialized view \nYou define a query that retrieves the desired data from one or more source tables for creating materialized views. This query may include filtering, aggregations, joins, and other operations as needed. \n
The database initially populates the materialized view by running the defined query against the source data. The result of the query is stored as a physical table in the database, and this table represents the materialized view. \n
Update materialized view \nThe data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
You can use a materialized view to control who has access to specific data. You can filter information for users without giving them access to the source tables. This approach is practical if you want to control who has access to what data and how much of it they can see and interact with.","id":"seo-faq-pairs#what-are-the-benefits-of-materialized-views","customSort":"2"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"What are the use cases of materialized views?","faqAnswer":"
You can benefit from materialized views in many different scenarios. \n
Distribute filtered data \nIf you need to distribute recent data across many locations, like for a remote workforce, materialized views help. You replicate and distribute data to many sites using materialized views. The people needing access to data interact with the replicated data store closest to them geographically. \n
This system allows for concurrency and decreases network load. It’s an effective approach with read-only databases. \n
Analyze time series data \nMaterialized views provide timestamped snapshots of datasets, so you can model information changes over time. You can store precomputed aggregations of data, like monthly or weekly summaries. These uses are helpful for business intelligence and reporting platforms. \n
Remote data interaction \nIn distributed database systems, you can use materialized views to optimize queries involving data from remote servers. Rather than repeatedly fetching data from a remote source, you can fetch and store data in a local materialized view. This reduces the need for network communication and improving performance. \n
For example, if you receive data from an external database or through an API, a materialized view consolidates and helps process it. \n
Periodic batch processing \nMaterialized views are helpful for situations where periodic batch processing is required. For instance, a financial institution might use materialized views to store end-of-day balances and interest calculations. Or they might store portfolio performance summaries, which can be refreshed at the end of each business day.","id":"seo-faq-pairs#what-are-the-use-cases-of-materialized-views","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"How do materialized views work?","faqAnswer":"
Materialized views work by precomputing and storing the results of a specific query as a physical table in the database. The database performs the precomputation at regular intervals, or users can trigger it by specific events. Administrators monitor the performance and resource utilization of materialized views to ensure they continue to meet their intended purpose. \n
Here's a general overview of how materialized views work. \n
Create materialized view \nYou define a query that retrieves the desired data from one or more source tables for creating materialized views. This query may include filtering, aggregations, joins, and other operations as needed. \n
The database initially populates the materialized view by running the defined query against the source data. The result of the query is stored as a physical table in the database, and this table represents the materialized view. \n
Update materialized view \nThe data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
Materialized views provide timestamped snapshots of datasets, so you can model information changes over time. You can store precomputed aggregations of data, like monthly or weekly summaries. These uses are helpful for business intelligence and reporting platforms. \n
Remote data interaction \nIn distributed database systems, you can use materialized views to optimize queries involving data from remote servers. Rather than repeatedly fetching data from a remote source, you can fetch and store data in a local materialized view. This reduces the need for network communication and improving performance. \n
For example, if you receive data from an external database or through an API, a materialized view consolidates and helps process it. \n
Periodic batch processing \nMaterialized views are helpful for situations where periodic batch processing is required. For instance, a financial institution might use materialized views to store end-of-day balances and interest calculations. Or they might store portfolio performance summaries, which can be refreshed at the end of each business day.","id":"seo-faq-pairs#what-are-the-use-cases-of-materialized-views","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"How do materialized views work?","faqAnswer":"
Materialized views work by precomputing and storing the results of a specific query as a physical table in the database. The database performs the precomputation at regular intervals, or users can trigger it by specific events. Administrators monitor the performance and resource utilization of materialized views to ensure they continue to meet their intended purpose. \n
Here's a general overview of how materialized views work. \n
Create materialized view \nYou define a query that retrieves the desired data from one or more source tables for creating materialized views. This query may include filtering, aggregations, joins, and other operations as needed. \n
The database initially populates the materialized view by running the defined query against the source data. The result of the query is stored as a physical table in the database, and this table represents the materialized view. \n
Update materialized view \nThe data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
Materialized views are helpful for situations where periodic batch processing is required. For instance, a financial institution might use materialized views to store end-of-day balances and interest calculations. Or they might store portfolio performance summaries, which can be refreshed at the end of each business day.","id":"seo-faq-pairs#what-are-the-use-cases-of-materialized-views","customSort":"3"},"metadata":{"tags":[{"id":"seo-faq-pairs#faq-collections#materialized-view","name":"materialized-view","namespaceId":"seo-faq-pairs#faq-collections","description":"
materialized-view","metadata":{}}]}},{"fields":{"faqQuestion":"How do materialized views work?","faqAnswer":"
Materialized views work by precomputing and storing the results of a specific query as a physical table in the database. The database performs the precomputation at regular intervals, or users can trigger it by specific events. Administrators monitor the performance and resource utilization of materialized views to ensure they continue to meet their intended purpose. \n
Here's a general overview of how materialized views work. \n
Create materialized view \nYou define a query that retrieves the desired data from one or more source tables for creating materialized views. This query may include filtering, aggregations, joins, and other operations as needed. \n
The database initially populates the materialized view by running the defined query against the source data. The result of the query is stored as a physical table in the database, and this table represents the materialized view. \n
Update materialized view \nThe data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
The data in a materialized view needs to be periodically updated to reflect changes in the underlying data in the source tables. The data refresh frequency depends on the use case and requirements. \n
Next, we explain a few common approaches for data refresh. \n
Full refresh \nThe materialized view is completely recomputed and overwritten with the latest query results. It is the simplest approach but can be resource-intensive, especially for large materialized views. \n
Incremental refresh \nOnly the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
Only the changes in the underlying data are applied to the materialized view. It can be more efficient than a full refresh when dealing with large datasets and frequent updates. \n
On-demand refresh \nSome systems allow materialized views to be refreshed on demand, triggered by specific events or user requests. This gives more control over when the data is updated, but it requires careful management to ensure the materialized view remains up-to-date. \n
Technical variations in different systems \nEach database management system has distinct methods for creating a materialized view. \n
Each database management system has distinct methods for creating a materialized view. \n