JSONPath icon indicating copy to clipboard operation
JSONPath copied to clipboard

Filter Expression With Equals String

Open SoftCreatR opened this issue 5 years ago • 0 comments

Test Data:

[
   {
      "key":"some"
   },
   {
      "key":"value"
   },
   {
      "key":null
   },
   {
      "key":0
   },
   {
      "key":1
   },
   {
      "key":-1
   },
   {
      "key":""
   },
   {
      "key":{
         
      }
   },
   {
      "key":[
         
      ]
   },
   {
      "key":"valuemore"
   },
   {
      "key":"morevalue"
   },
   {
      "key":[
         "value"
      ]
   },
   {
      "key":{
         "some":"value"
      }
   },
   {
      "key":{
         "key":"value"
      }
   },
   {
      "some":"value"
   }
]

Selector:

$[?(@.key=="value")]

Result (Proposal A):

--- Expected
+++ Actual
@@ @@
-'[{"key":"value"}]'
+'[{"key":"value"},{"key":0}]'

https://cburgmer.github.io/json-path-comparison/results/filter_expression_with_equals_string.html

SoftCreatR avatar Nov 03 '20 14:11 SoftCreatR