# Dashboard Node "chart" 2 lines from "Infuxdb in" Node

**URL:** https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597
**Category:** Dashboard
**Created:** [5 January 2021 15:56 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597 "2021-01-05T15:56:27Z")
**Posts on this page:** 6
**Page:** 1

<div class="post-metadata">

### Author: ![RobTester](https://avatars.discourse-cdn.com/v4/letter/r/e47c2d/32.png) [@RobTester](https://discourse.nodered.org/u/RobTester)
#### Post date: [5 January 2021 15:56 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/1 "2021-01-05T15:56:28Z")

</div>

Hi,

I looking for a way to have 2 lines in Node Red dashboard Chart. I can't figure out how to to this.  
This are the debugs from the two Nodes that I want in the Chart.

Can someone help me with this.

5-1-2021 16:51:54[node: 259be37c.702ec4]  
msg.payload : array[1]  
array[1]  
0: object  
time: "2021-01-05T15:51:37.000Z"  
last: 0.04648078918457031

5-1-2021 16:51:54[node: e3d4a561.1cc53]  
msg.payload : array[1]  
array[1]  
0: object  
time: "2021-01-05T15:51:37.000Z"  
last: 0.10790086364746093

Thanks

---

<div class="post-metadata">

### Author: ![E1cid](https://sea2.discourse-cdn.com/flex026/user_avatar/discourse.nodered.org/e1cid/32/77971_2.png) [@E1cid](https://discourse.nodered.org/u/E1cid)
#### Post date: [5 January 2021 17:15 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/3 "2021-01-05T17:15:16Z")

</div>

From the help info. `Multiple series can be shown on the same chart by using a different msg.topic value on each input message.`

So each line will; nedd its own msg.topic value.

---

<div class="post-metadata">

### Author: ![RobTester](https://avatars.discourse-cdn.com/v4/letter/r/e47c2d/32.png) [@RobTester](https://discourse.nodered.org/u/RobTester)
#### Post date: [5 January 2021 18:24 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/4 "2021-01-05T18:24:52Z")

</div>

Hi,  
How do I add a msg.topic to my Node "Influx Db in" it has no topic field?

---

<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: [5 January 2021 18:28 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/5 "2021-01-05T18:28:29Z")

</div>

Are you trying to fill a chart with historical data or add real time data? If you are filling with historical data then you need to put everything into one message. There is a link in the help text for the the chart which tells you the format needed.

Edit, back at my computer now, the link is [node-red-dashboard/Charts.md at master · node-red/node-red-dashboard · GitHub](https://github.com/node-red/node-red-dashboard/blob/master/Charts.md)

---

<div class="post-metadata">

### Author: ![RobTester](https://avatars.discourse-cdn.com/v4/letter/r/e47c2d/32.png) [@RobTester](https://discourse.nodered.org/u/RobTester)
#### Post date: [6 January 2021 06:48 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/7 "2021-01-06T06:48:16Z")

</div>

Thanks for the info, it works now. I ad a function Node to each output of my Influx Nodes. And then connect them all to one Chart Node.

Function Node Line1

msg.topic = "Line 1"  
return msg;

Function Node Line 2

msg.topic = "Line 2"  
return msg;

---

<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: [20 January 2021 06:48 UTC](https://discourse.nodered.org/t/dashboard-node-chart-2-lines-from-infuxdb-in-node/38597/8 "2021-01-20T06:48:22Z")

</div>

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