# Range error - The value "NaN" is invalid

**URL:** <https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778>\
**Category:** General\
**Created:** [23 June 2020 06:27 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778 "2020-06-23T06:27:21Z")\
**Posts on this page:** 8\
**Page:** 2

<div class="post-metadata">

**Author:** ![jan12](https://avatars.discourse-cdn.com/v4/letter/j/bc79bd/32.png) [@jan12](https://discourse.nodered.org/u/jan12)\
**Post date:** [23 June 2020 07:42 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/21 "2020-06-23T07:42:15Z")

</div>

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/3/f/3ff466f7f364e97f0235c9137607f36b8f93c83b.png)

 ![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/5/6/56448464c20aecea1ed21dad5b4e7ef305d64e00.png)

now the values get in ?

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [23 June 2020 07:46 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/22 "2020-06-23T07:46:10Z")

</div>

The values are what is received by those two _blue_ nodes..... `ID` and `DATA`.

Now, I strongly suggest you do what @knolleary said and contact the person who made that node.

In the mean time we can try to _cheat_.

Click on the two lines shown here by the two green circles.

We are going to work on the nodes which are pointed at by the arrows.

![flow](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/e/f/efe4380239f4a4d81067ec7a95c579fbf116a09f.png)

When you click on one of the lines it will turn orange.  
Press the `delete` and the line will disappear.

Repeat with the other line.

then press the `deploy` button (top right)

Oh, after that:

Double click on the `function` node. Then click in the area where the code is.  
Select all the code and post it here.

---

<div class="post-metadata">

**Author:** ![jan1](https://avatars.discourse-cdn.com/v4/letter/j/91b2a8/32.png) [@jan1](https://discourse.nodered.org/u/jan1)\
**Post date:** [23 June 2020 07:59 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/23 "2020-06-23T07:59:58Z")

</div>

![image](https://us1.discourse-cdn.com/flex026/uploads/nodered/original/3X/a/1/a19bb2de16f918de9a5e7b60605ff805cfb6cac8.png)

I have to send in a new name - may only send a few ansvars the first day ☹

---

<div class="post-metadata">

**Author:** ![Trying\_to\_learn](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/trying_to_learn/32/28400_2.png) [@Trying\_to\_learn](https://discourse.nodered.org/u/Trying_to_learn)\
**Post date:** [23 June 2020 08:02 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/24 "2020-06-23T08:02:42Z")

</div>

(On the posting limit: You should have edited you older posts.... But anyway.)

Ok, that isn't causing the problem. I think it is the next node. ☹  
Sorry. This is way way **WAY** beyond my knowledge base / skill set / ability.

I see @knolleary is replying again. But as I said before, you do need to get in touch with the people/person who wrote that node.

Good luck.

---

<div class="post-metadata">

**Author:** ![jan1](https://avatars.discourse-cdn.com/v4/letter/j/91b2a8/32.png) [@jan1](https://discourse.nodered.org/u/jan1)\
**Post date:** [23 June 2020 08:04 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/25 "2020-06-23T08:04:05Z")

</div>

thanks for your help 🙂

---

<div class="post-metadata">

**Author:** ![knolleary](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/knolleary/32/3_2.png) [@knolleary](https://discourse.nodered.org/u/knolleary)\
**Post date:** [23 June 2020 08:05 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/26 "2020-06-23T08:05:08Z")

</div>

@jan1 please don't create multiple accounts. Edit previous posts to provide more details rather than add lots of individual posts.

The problem here is you have `id` and `data` coming from two different nodes. They arrive at the Function node as separate events.

If you want to do something with a values from both nodes at the same time, you need to join them together into a single message.

There is a recipe in the cookbook for that: [https://cookbook.nodered.org/basic/join-streams](https://cookbook.nodered.org/basic/join-streams)

---

<div class="post-metadata">

**Author:** ![jan1](https://avatars.discourse-cdn.com/v4/letter/j/91b2a8/32.png) [@jan1](https://discourse.nodered.org/u/jan1)\
**Post date:** [23 June 2020 08:08 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/27 "2020-06-23T08:08:06Z")

</div>

> [@knolleary](#):
>
> lease don't create multiple accounts. Edit previous posts to provide more details rather than add lots of individual posts.
> 
> The problem here is you have `id` and `data` coming from two different nodes. They arrive at the Function node as separate events.
> 
> If you want to do something with a values from both nodes at the same time, you need to join them together into a single message.
> 
> There is a recipe in the cookbook for that: [Create a single message from separate streams of messages : Node-RED](https://cookbook.nodered.org/basic/join-streams)

Thanks I will delete one account and thanks for your help.  
I am desperate because i have to take an examenation in two days - thanks

---

<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:** [22 August 2020 08:08 UTC](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778/28 "2020-08-22T08:08:19Z")

</div>

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

[Previous page](https://discourse.nodered.org/t/range-error-the-value-nan-is-invalid/28778.md?page=1)
