You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
Copy file name to clipboardExpand all lines: articles/synapse-analytics/sql/develop-materialized-view-performance-tuning.md
+11-4Lines changed: 11 additions & 4 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -6,7 +6,7 @@ manager: craigg
6
6
ms.service: synapse-analytics
7
7
ms.topic: conceptual
8
8
ms.subservice: sql
9
-
ms.date: 04/15/2020
9
+
ms.date: 03/01/2023
10
10
ms.author: xiaoyul
11
11
ms.reviewer: nibruno; wiassaf
12
12
---
@@ -135,7 +135,10 @@ GROUP BY A, C
135
135
136
136
**Not all performance tuning requires query change**
137
137
138
-
The data warehouse optimizer can automatically use deployed materialized views to improve query performance. This support is applied transparently to queries that don't reference the views and to queries that use aggregates unsupported in materialized views creation. No query change is needed. You can check a query's estimated execution plan to confirm if a materialized view is used.
138
+
The data warehouse optimizer can automatically use deployed materialized views to improve query performance. This support is applied transparently to queries that don't reference the views and to queries that use aggregates unsupported in materialized views creation. No query change is needed. You can check a query's estimated execution plan to confirm if a materialized view is used.
139
+
140
+
- For more information on retrieving the actual execution plan, see [Monitor your Azure Synapse Analytics dedicated SQL pool workload using DMVs](/azure/synapse-analytics/sql-data-warehouse/sql-data-warehouse-manage-monitor#monitor-query-execution).
141
+
- You can retrieve an [estimated execution plan through SQL Server Management Studio (SSMS)](/sql/relational-databases/performance/display-the-estimated-execution-plan?view=azure-sqldw-latest&preserve-view=true) or [SET SHOWPLAN_XML](/sql/t-sql/statements/set-showplan-xml-transact-sql?view=azure-sqldw-latest&preserve-view=true).
139
142
140
143
**Monitor materialized views**
141
144
@@ -271,7 +274,9 @@ ORDER BY t_s_secyear.customer_id
271
274
OPTION ( LABEL ='Query04-af359846-253-3');
272
275
```
273
276
274
-
Check the query's estimated execution plan. There are 18 shuffles and 17 joins operations, which take more time to execute. Now let's create one materialized view for each of the three sub-SELECT statements.
277
+
Check the query's [estimated execution plan](/sql/relational-databases/performance/display-the-estimated-execution-plan.md). There are 18 shuffles and 17 joins operations, which take more time to execute.
278
+
279
+
Now, let's create one materialized view for each of the three sub-SELECT statements.
275
280
276
281
```sql
277
282
CREATE materialized view nbViewSS WITH (DISTRIBUTION=HASH(customer_id)) AS
@@ -361,4 +366,6 @@ With materialized views, the same query runs much faster without any code change
361
366
## Next steps
362
367
363
368
For more development tips, see [Synapse SQL development overview](develop-overview.md).
364
-
369
+
370
+
-[Monitor your Azure Synapse Analytics dedicated SQL pool workload using DMVs](/azure/synapse-analytics/sql-data-warehouse/sql-data-warehouse-manage-monitor).
0 commit comments