jsonquerylang / jsonquery

A lightweight, flexible, and expandable JSON query language
https://jsonquerylang.org/
Other
33 stars 0 forks source link

Array of Arrays #4

Open DaveyJake opened 6 days ago

DaveyJake commented 6 days ago

Can you provide an example of how to use jsonquery to filter a multidimensional array aka an array of arrays?

For example, how would I go about filtering these bid elements in order to group them by matching properties and adding a new count property?

{
  "bids": [
    [
      "67141.39",
      "0.04299999",
      "36e1216e-93ed-48e2-acc7-d9e348b1c880"
    ],
    [
      "67141.39",
      "0.00022876",
      "d459b1d0-4eea-46e2-99a0-f87b4d136b3d"
    ],
    [
      "67140.56",
      "0.04299999",
      "83ef5611-e636-4d73-9fda-1d0988222119"
    ],
    [
      "67139.72",
      "0.08244684",
      "3a735d20-9303-49cc-a729-83ead06563dc"
    ],
    [
      "0.1",
      "10",
      "55c9ec6d-dd01-47e3-9086-550f345f5017"
    ],
    [
      "0.1",
      "1",
      "4b5641e7-d543-4d07-b76c-1a2a880876a2"
    ],
    [
      "0.1",
      "200",
      "b5da2b53-68fb-40d0-b3e9-5a7a08b25848"
    ],
    [
      "0.1",
      "32.5038",
      "53b8d0c1-eaf4-4780-97af-2e4764fbefa6"
    ],
    [
      "0.1",
      "10",
      "5eeffc24-3cd1-4eca-bdf3-177f02171586"
    ],
    [
      "0.1",
      "10",
      "635d658d-b591-4283-b774-f692e1354f2f"
    ]
  ]
}