Skip to content
This repository was archived by the owner on Aug 13, 2026. It is now read-only.

Regex Key Match

Luke Bakken edited this page Oct 5, 2016 · 1 revision

Matching Records in a Map Phase with a Regex

Source File on GitHub

As you can see, this is a simple function written in JavaScript. Its original use was to return keys that match a given regex.

This is the entirety of the function:

function keyMatch(value, arg){ 
  if (value.values[0].data.match(arg)) { 
    return [value.key] 
  } else {
    return []
  }
}

Clone this wiki locally