Skip to content
This repository has been archived by the owner on Oct 23, 2024. It is now read-only.

JSONPath 系列问题 #4509

Open
Mr-Xzz opened this issue May 17, 2024 · 0 comments
Open

JSONPath 系列问题 #4509

Mr-Xzz opened this issue May 17, 2024 · 0 comments

Comments

@Mr-Xzz
Copy link

Mr-Xzz commented May 17, 2024

  1. 逻辑表达式不支持嵌套:

报语法错误:

$[?((@.kind != 'kind-or1' || @.kind == 'kind-or2') && (@.domain == 'domain-or1' || @.domain == 'domain-or2') && @.name == 'name')]

只能这么写:

$[?(@.kind != 'kind-or1' || @.kind == 'kind-or2')][?(@.domain == 'domain-or1' || @.domain == 'domain-or2')][?(@.name == 'name')]

  1. 当筛选值包含单引号的时候,无论怎么写都报错。

尝试的写法:

  • $[?(@.name=='\'')]
  • $[?(@.name=='\\'')]
  • $[?(@.name==''')]
  • $[?(@.name=='''')]
Sign up for free to subscribe to this conversation on GitHub. Already have an account? Sign in.
Labels
None yet
Projects
None yet
Development

No branches or pull requests

1 participant