Skip to content

Add JSON path query examples - #8375

Open
josbeir wants to merge 1 commit into
5.nextfrom
docs/55-json-path-examples
Open

josbeir wants to merge 1 commit into
5.nextfrom
docs/55-json-path-examples

Conversation

@josbeir

@josbeir josbeir commented Oct 24, 2026

Copy link
Copy Markdown
Contributor

Show JsonPathExpression usage and explain PostgreSQL version differences.

Refs cakephp/cakephp#19642.

@josbeir

josbeir commented Oct 25, 2026

Copy link
Copy Markdown
Contributor Author

@othercorey looks good?

`JsonPathExpression` was added.
:::

Use `jsonValue()` to extract a value from a JSON column:

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I would suggest adding the path specific info/examples first and then list out functions that use them like jsonValue.

returning types and variable names are not sanitized, so define those in
application code rather than taking them from request data.

Clause support varies by database and version. PostgreSQL 17+ uses native

Copy link
Copy Markdown
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

postgresql supports most of the sql standard, but other engines support a couple clauses. I don't know that extensive documentation here is needed, but I might split them up like that since there are so few.

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.

3 participants