# Read Data from Json object and push to an array

**URL:** <https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377>\
**Category:** General\
**Created:** [16 October 2020 21:07 UTC](https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377 "2020-10-16T21:07:12Z")\
**Posts on this page:** 4\
**Page:** 1

<div class="post-metadata">

**Author:** ![neelanjan](https://avatars.discourse-cdn.com/v4/letter/n/7cd45c/32.png) [@neelanjan](https://discourse.nodered.org/u/neelanjan)\
**Post date:** [16 October 2020 21:07 UTC](https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377/1 "2020-10-16T21:07:12Z")

</div>

Need to read data from json object which is server data at an interval of 1 sec...and then need to push 1min data(60 samples) into an array...is it possible using node red.

---

<div class="post-metadata">

**Author:** ![Steve-Mcl](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/steve-mcl/32/4826_2.png) [@Steve-Mcl](https://discourse.nodered.org/u/Steve-Mcl)\
**Post date:** [16 October 2020 21:56 UTC](https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377/2 "2020-10-16T21:56:43Z")

</div>

> [@neelanjan](#):
>
> is it possible using node red.

Yes it is.

There’s a great page in the docs that will explain how to use the debug panel to find the right path to any data item.

[https://nodered.org/docs/user-guide/messages](https://nodered.org/docs/user-guide/messages)

As for pushing to an array, you will likely need to store the array in context & retrieve it for adding new data. Read up on node-red context.

---

<div class="post-metadata">

**Author:** ![dceejay](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/dceejay/32/38_2.png) [@dceejay](https://discourse.nodered.org/u/dceejay)\
**Post date:** [16 October 2020 22:10 UTC](https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377/3 "2020-10-16T22:10:59Z")

</div>

Or possibly the join node set to manually crest an array of 60 items.

---

<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:** [30 October 2020 22:11 UTC](https://discourse.nodered.org/t/read-data-from-json-object-and-push-to-an-array/34377/4 "2020-10-30T22:11:12Z")

</div>

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