Skip to content

[GH-1781] Document parameterized spatial SQL queries - #3387

Merged
jiayuasu merged 2 commits into
apache:masterfrom
jiayuasu:codex/gh-1781-parameterized-query-docs
Sep 22, 2026
Merged

jiayuasu merged 2 commits into
apache:masterfrom
jiayuasu:codex/gh-1781-parameterized-query-docs

Conversation

@jiayuasu

Copy link
Copy Markdown
Member

Did you read the Contributor Guide?

Yes, I have read the Contributor Rules and Contributor Development Guide.

Is this PR related to a ticket?

Related to #1781. This documents supported query forms; it does not implement direct Shapely-object binding.

What changes were proposed in this PR?

Add matching English and Chinese tutorial examples showing how to bind WKT values through named SQL parameters and reference a DataFrame through a keyword placeholder. Explain which placeholders remain unquoted and how to bind a Shapely geometry's WKB representation for reconstruction with ST_GeomFromWKB.

These examples use the existing SparkSession.sql interface returned by SedonaContext; no runtime API changes are needed.

How was this patch tested?

  • Extracted and executed the exact English examples on local Spark 3.4.4 with worktree Python source and an existing Sedona snapshot JAR. The spatial query returned only id=1, and the WKB example returned POINT (1 1). This was not a fresh JVM build.
  • Verified that Chinese and English code examples are identical.
  • Applicable repository hooks and whitespace checks passed.
  • Bilingual MkDocs build passed, and both generated tutorial pages contain the new section. Existing missing generated-API documentation and link warnings remain.

Did this PR include necessary documentation updates?

Yes, this PR updates the English and Chinese SQL tutorials.

@jiayuasu jiayuasu added this to the sedona-2.0.0 milestone Sep 22, 2026
@jiayuasu jiayuasu linked an issue Sep 22, 2026 that may be closed by this pull request
@jiayuasu
jiayuasu merged commit f02a851 into apache:master Sep 22, 2026
11 checks passed
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.

Sedona parameterized queries

1 participant