cancel
Showing results for 
Search instead for 
Did you mean: 

Map Values into an Array

alex_panganiban
Contributor

I have a document that contains several records with key/value pairs.

[
{“DOB_Date”: “1960-07-04”, “First_Name”: “Bobby”, “ID”: “99999”, “Last_Name”: “Fischer”},
{“DOB_Date”: “1970-08-24”, “First_Name”: “Wade”, “ID”: “99988”, “Last_Name”: “Boggs”}.
{“DOB_Date”: “2005-04-27”, “First_Name”: “Billie Jean”, “ID”": “88888”, “Last_Name”: “King”}
]

I want to create an array that contains only the values, so it looks like this:

[
dataValues: {[“1960-07-04”, “Bobby”, "99999”, “Fischer”]},
dataValues: {[“1970-08-24”, “Wade”, “ID”: “99988”, “Boggs”]}.
dataValues: {[“2005-04-27”, “Billie Jean”, “88888”, “King”]}
]

How can I do this? I’m stumped.

1 ACCEPTED SOLUTION

SpiroTaleski
Valued Contributor

@alex.panganiban.guild

I am attaching one simple pipe, so hopefully you will find helpful:

test_2022_11_23.slp (3.7 KB)

BR,
Spiro Taleski

View solution in original post

2 REPLIES 2

SpiroTaleski
Valued Contributor

@alex.panganiban.guild

I am attaching one simple pipe, so hopefully you will find helpful:

test_2022_11_23.slp (3.7 KB)

BR,
Spiro Taleski

alex_panganiban
Contributor

OMGosh! So simple, yet impactful. Exactly what I was looking for. I really was overcomplicating it by using map functions and callbacks. Thank you so much!