Mysql-r2 define port

I am trying to connect to a DB at port 1433. I can connect to the DB via SQL Server Management Studio without issue. But when I run node-red from the same PC, i cannot connect to the db. I've tried both the mysql and the mysql-r2 nodes.

With the MySQL node, I can enter all data without issue. But it just times out. quadruple checked that the user and password are valid. Host and Port are correct along with Database.

With the mysql-r2 node, there is no reference as to where to specify a port in the instructions. When i set it up without a port, i get:
"Error: connect ECONNREFUSED XX.XXX.XX.XX:3306"

Ok, this makes sense, its the wrong port. When i set the host to XX.XXX.XX.XX:1433 I get:
"Error: getaddrinfo ENOTFOUND 10.100.96.53:1433".

Its not refused so i'm thinking that maybe its not interpreting the port correctly.

What is the correct way to specify a port on mysql-r2 node?

Welcome to the forum @dgagliadi

How did you install node-red? Is it a Docker install?
What version of node-red and nodejs are you using? Use node -v for the latter.

When you say you tried the mysql node do you mean node-red-node-mysql? That is the usual node used and it should work ok.

For help with the other node you mention you may have to ask the author on the node's github page, if it has one.

Yes, node-red-node-mysql:
image

Node-RED version 3.0.2
Nodejs version 16.17.1
image

This one is installed on my local machine, which I can connect to the same DB with same credentials.

I don't understand what you mean by 'this one'. Do you mean you have a different node-red install that does connect to the db?

You are using nodes designed to access MySQL or MariaDB, but your DBMS seems to be MS SQLPlus (sorry, not sure of the name[s] of Microsoft's database offering).

Have you tried node-red-contrib-mssql-plus?

Outstanding! This was the issue. Thank you very much

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