Skip to content

Commit dc660f0

Browse files
Merge pull request #237250 from ilijazagorac/patch-11
Update create-use-views.md
2 parents bc5e3f4 + 0f6aa85 commit dc660f0

File tree

1 file changed

+5
-1
lines changed

1 file changed

+5
-1
lines changed

articles/synapse-analytics/sql/create-use-views.md

Lines changed: 5 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -93,7 +93,11 @@ FROM
9393
) AS nyc
9494
```
9595

96-
The partitioned views will perform folder partition elimination if you query this view with the filters on the partitioning columns. This might improve performance of your queries.
96+
Partitioned views can improve the performance of your queries by performing partition elimination when you query them with filters on the partitioning columns. However, not all queries support partition elimination, so it's important to follow some best practices.
97+
98+
To ensure partition elimination, avoid using subqueries in filters, since they can interfere with the ability to eliminate partitions. Instead, pass the result of the subquery as a variable to the filter.
99+
100+
When using JOINs in SQL queries, declare the filter predicate as NVARCHAR to reduce the complexity of the query plan and increase the probability of correct partition elimination. Partition columns are typically inferred as NVARCHAR(1024), so using the same type for the predicate avoids the need for an implicit cast, which can increase query plan complexity.
97101

98102
### Delta Lake partitioned views
99103

0 commit comments

Comments
 (0)