B4J Question How do I use the JRDC when the database and JRDC are on different servers?

pengbm

Member
Licensed User
Longtime User
I rented a cloud database, so my database and JRDC are located in different servers. I can connect to my cloud database using Navicat, but I can't connect to the WEBSITE using JRDC, I don't know what the problem is.

I changed the JdbcUrl of the config file to < database external IP >: database port number/database name

I will now change it to:

< database external IP > : 17178 /test

Don't know if the format is correct?
So I want to ask you if my format is correct:

http://XXX (database external IP) : 17178 (this Java server port number does not change?) /test
 

josejad

Expert
Licensed User
Longtime User
< database external IP > : 17178 /test
This URL is just to know if the jRDC2 is working and it can connect to your database. So, to test you should write:

B4X:
http://your jRDC2 ip: 17178/test
 
Upvote 0

pengbm

Member
Licensed User
Longtime User
It turned out to be so, I have been misunderstood, thank you! However, it shows that The RemoteServer is running (05/31/2022 14:55:56)
Error fetching connection.There must still be something wrong...
 
Upvote 0

josejad

Expert
Licensed User
Longtime User
Ok, then we know the jRDC2 server is running, but there's a problem connecting to your database.

Post your config.properties (hiding the sensitive data), your database type (ms sql, mysql, ...)
Maybe useful to see how you've set up Navicat to connect your database.
 
Upvote 0

josejad

Expert
Licensed User
Longtime User
By the way

B4X:
http://your jRDC2 ip: 17178/test

is the address you have to use in your clients apps (B4A, B4J, ...) to access your database.
 
Upvote 0

pengbm

Member
Licensed User
Longtime User
It turned out to be so, I have been misunderstood, thank you! However, it shows that The RemoteServer is running (05/31/2022 14:55:56)
Error fetching connection.There must still be something wrong...
Hahaha, I just solved, the original connector version is not right, thank you for your help! I wish you all the best!
 
Upvote 0
Top