title: Compare 2 JSON arrays to get matching and un-matching outputs
body: <p>I need to compare 2 JSON arrays using Mule 4 dataweave 2.0 to get matching and un-matching outputs.
  The sample input JSON payload is given below:</p>
  
  <pre><code>[
      {
          "CODE": "A11",
          "NAME": "Alpha",
          "ID": "C10000"
      },
      {
          "CODE": "B12",
          "NAME": "Bravo",
          "ID": "B20000"
      },
      {
          "CODE": "C11",
          "NAME": "Charlie",
          "ID": "C30000"
      },
      {
          "CODE": "D12",
          "NAME": "Delta",
          "ID": "D40000"
      },
      {
          "CODE": "E12",
          "NAME": "Echo",
          "ID": "E50000"
      }
  ]
  </code></pre>
  
  <p>This has to be compared to the below on ID/IDENTITY field.</p>
  
  <pre><code>[
      {
          "IDENTITY": "D40000",
          "NM": "Delta"
      },
      {
          "IDENTITY": "C30000",
          "NM": "Charlie"
      }
  ]
  </code></pre>
  
  <p>My expected output is 2 variable arrays containing matching and un-matching objects:</p>
  
  <pre><code>varMatch: 
  [
      {
          "CODE": "C11",
          "NAME": "Charlie",
          "ID": "C30000"
      },
      {
          "CODE": "D12",
          "NAME": "Delta",
          "ID": "D40000"
      }
  ]
  varUnmatch:
  [
      {
          "CODE": "A11",
          "NAME": "Alpha",
          "ID": "C10000"
      },
      {
          "CODE": "B12",
          "NAME": "Bravo",
          "ID": "B20000"
      },
      {
          "CODE": "E12",
          "NAME": "Echo",
          "ID": "E50000"
      }
  ]
  </code></pre>