Skip to content

Conversation

@SergeyKandalintsev
Copy link

Which Delta project/connector is this regarding?

  • Spark
  • Standalone
  • Flink
  • Kernel
  • Other (Docs)

Description

In the docs/delta-batch.mdx page, the Python examples that demonstrate partition pruning with generated columns use an invalid SQL predicate on eventTime.

Both examples currently use:

spark.sql('SELECT * FROM default.events WHERE eventTime >= "2020-10-01 00:00:00" <= "2020-10-01 12:00:00"')

This chained comparison is not valid Spark SQL syntax and does not express the intended time range filter.
This PR fixes the SQL predicates used in two Python examples in docs/delta-batch.mdx. Both examples are updated to use an explicit AND between the lower and upper bounds

How was this patch tested?

Built locally.

Does this PR introduce any user-facing changes?

No

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment

Labels

None yet

Projects

None yet

Development

Successfully merging this pull request may close these issues.

1 participant