# How can i get only the "true/false" value from array

**URL:** <https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448>\
**Category:** General\
**Created:** [6 March 2022 17:35 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448 "2022-03-06T17:35:31Z")\
**Posts on this page:** 5\
**Page:** 1

<div class="post-metadata">

**Author:** ![retegi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/retegi/32/62526_2.png) [@retegi](https://discourse.nodered.org/u/retegi)\
**Post date:** [6 March 2022 17:35 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448/1 "2022-03-06T17:35:31Z")

</div>

How can i get only the "true/false" value from array to after send to Bomba1Marcha?  
I get an array, but i only need true false value.

 ![imagen](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/b/5b324620d32df24449e1cd29cbc89be2520beefd.png)

![imagen](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/4/7/472c5abdf9221067dc647d0d93f9bef9a1c60083.png)

Thanks.

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [6 March 2022 17:49 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448/2 "2022-03-06T17:49:52Z")

</div>

You can use a Change node to move it into msg.payload.

There’s a great page in the docs ([Working with messages : Node-RED](https://nodered.org/docs/user-guide/messages)) that will explain how to use the debug panel to find the right path to any data item.

Pay particular attention to the part about the buttons that appear under your mouse pointer when you over hover a debug message property in the sidebar.

![BX00Cy7yHi](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/b/d/bd1f333a9e043b061b39917c328b0094d3e52d30.gif)

---

<div class="post-metadata">

**Author:** ![retegi](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/retegi/32/62526_2.png) [@retegi](https://discourse.nodered.org/u/retegi)\
**Post date:** [6 March 2022 18:43 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448/3 "2022-03-06T18:43:28Z")

</div>

Next is ok! Thanks.

msg.payload = msg.payload[0].run  
return msg;

---

<div class="post-metadata">

**Author:** ![Colin](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/colin/32/17040_2.png) [@Colin](https://discourse.nodered.org/u/Colin)\
**Post date:** [6 March 2022 21:41 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448/4 "2022-03-06T21:41:03Z")

</div>

That would be more efficient in a Change node.  
Move msg.payload[0].run To msg.payload

---

<div class="post-metadata">

**Author:** ![system](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/1X/d073cd938eafa2e558d7c2cd59003b3ef4963033.png) [@system](https://discourse.nodered.org/u/system)\
**Post date:** [5 May 2022 21:41 UTC](https://discourse.nodered.org/t/how-can-i-get-only-the-true-false-value-from-array/59448/5 "2022-05-05T21:41:48Z")

</div>

This topic was automatically closed 60 days after the last reply. New replies are no longer allowed.
