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
<!--
Thanks for opening a pull request!
-->
<!-- In the case this PR will resolve an issue, please replace
${GITHUB_ISSUE_ID} below with the actual Github issue id. -->
<!-- Closes #${GITHUB_ISSUE_ID} -->
# Rationale for this change
# Are these changes tested?
# Are there any user-facing changes?
<!-- In the case of user-facing changes, please add the changelog label.
-->
Copy file name to clipboardExpand all lines: mkdocs/docs/expression-dsl.md
+2-17Lines changed: 2 additions & 17 deletions
Display the source diff
Display the rich diff
Original file line number
Diff line number
Diff line change
@@ -17,7 +17,7 @@
17
17
18
18
# Expression DSL
19
19
20
-
The PyIceberg library provides a powerful expression DSL (Domain Specific Language) for building complex row filter expressions. This guide will help you understand how to use the expression DSL effectively. This DSL allows you to build type-safe expressions for use in the `row_filter` scan argument.
20
+
The PyIceberg library provides a powerful expression Domain Specific Language (DSL) for building complex row filter expressions. This guide will help you understand how to use the expression DSL effectively. This DSL allows you to build type-safe expressions for use in the `row_filter` scan argument.
21
21
22
22
They are composed of terms, predicates, and logical operators.
23
23
@@ -151,20 +151,6 @@ age_in_range = Not(
151
151
)
152
152
```
153
153
154
-
### Type Safety
155
-
156
-
The expression DSL provides type safety through Python's type system. When you create expressions, the types are checked at runtime:
157
-
158
-
```python
159
-
from pyiceberg.expressions import EqualTo
160
-
161
-
# This will work
162
-
age_equals_18 = EqualTo("age", 18)
163
-
164
-
# This will raise a TypeError if the field type doesn't match
165
-
age_equals_18 = EqualTo("age", "18") # Will fail if age is an integer field
166
-
```
167
-
168
154
## Best Practices
169
155
170
156
1.**Use Type Hints**: Always use type hints when working with expressions to catch type-related errors early.
0 commit comments