How to create a Database Connection

Written By Pete Sathianathan (Administrator)

Updated at January 7th, 2021

In this example, we will walk you through on how to create a database connection with an established database.

Steps 

1) Select the inject node (Under Software Components Menu), change the payload setting to string from the timestamp, and name the string SELECT * FROM user. Click deploy.

2) Select the Function node (Orange Node) from the function menu. Double click on the function node, add 

 msg.topic = msg.payload 

3) Select a MySQL node from Data Sources (under the Enterprise Services) menu and enter your created MySQL database and port number. 


4) Open up a console node and connect all the nodes and click on deploy.



Was this article helpful?