Skip to content

Commit

Permalink
Comments
Browse files Browse the repository at this point in the history
  • Loading branch information
theory committed Jul 8, 2024
1 parent 9e3d95a commit 5e097f5
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 1 deletion.
2 changes: 1 addition & 1 deletion .github/workflows/publish.yml
Original file line number Diff line number Diff line change
Expand Up @@ -6,7 +6,7 @@ jobs:
runs-on: ubuntu-latest
steps:
- name: Check out Source
uses: actions/checkout@v3
uses: actions/checkout@v4
- name: Build the Site
uses: docker://hugomods/hugo:base-0.128.2
with: { args: hugo }
Expand Down
2 changes: 2 additions & 0 deletions content/post/postgres/go-sqljson-path.md
Original file line number Diff line number Diff line change
Expand Up @@ -33,12 +33,14 @@ import (
)

func main() {
// Parse some JSON.
var value any
err := json.Unmarshal([]byte(`{"a":[1,2,3,4,5]}`), &value)
if err != nil {
log.Fatal(err)
}

// Parse a path expression and execute it on the JSON.
p := path.MustParse("$.a[*] ? (@ >= $min && @ <= $max)")
res, err := p.Query(
context.Background(),
Expand Down

0 comments on commit 5e097f5

Please sign in to comment.