Android Question RDC vs jRDC2, VPS Linux, and CRUD Examples

Agus Biyanto

New Member
Licensed User
Dear Erel

I am starting to program B4A, try RDC connection successful.
My question : is jRDC2 better than RDC, compatible to B4A?

My remote server environments :
- Cloud VPS, java 8, webserver running well
- CentOS 6 (64bit) with Webuzo control panel

Last week I was struggling setup RDC, since all tutorials are about Windows.

Until I found in this thread :
Here's a short tutorial for anyone that wants to run the RDC server on a Ubuntu server
https://www.b4x.com/android/forum/t...tor-rdc-connect-to-any-remote-db.31540/page-8
by @warwound <-- I am using Centos, but thanks a lot, really appreciate this!

However, that is for RDC, is there any setup guidance for jRDC2,
but linux / ubuntu / centos environment? Of course, I mean to remote db at cloud VPS.

Finally, great if together with CRUD examples (in B4A).
Thank you.

Rgds to all masters here,
Agus
 
Last edited:

inakigarm

Well-Known Member
Licensed User
Longtime User
Upvote 0

Agus Biyanto

New Member
Licensed User
First, thank you for @inakigarm replying my case, though sorry for my late response.

1. Back to the issue. I setup successfully RDC under my VPS spec as listed above.

2. I want to explore about jRDC2 because I read every where, it is much better than RDC.

3. I never tried on localhost window, because I didnt want to do double works.
Instead of installing localhost server, I always tried all stuffs with my B4A IDE and DIRECTLY
access to MySql server on my VPS. So i can settled whatever problems happened.

4. Now, let me write the RDC concept based on my understanding : (on Centos system)
a) the script b4a-rdc.sh created by @warwound started jdbc server "mysql-connector-java-5.1.28-bin.jar"
b) this jdbc server communicates with MySql server, database whatever.
c) B4A program accessing the database using "DBRequestManager.bas" (contacting jdbc, port 17178)

5. I read https://www.b4x.com/android/forum/t...e-database-connector.61801/page-6#post-521240
@Enrique Gonzalez answering @achtrade and concern raised by @Cableguy
that jRDC2 can only be compiled under B4J, not B4A. Then I start missing the concept.

6. I read https://www.b4x.com/android/forum/threads/server-run-a-server-on-a-vps.60378/#content
@Erel said "mysql-connector-java-5.1.28-bin.jar" needs to be started. This file is already started!

7. Suppose I want to program using B4A IDE, then THE NEW "DBRequestManager.bas" should be
responsible to contact "mysql-connector-java-5.1.28-bin.jar" port 17178,
then what is jRDC2 all about?? I have downloaded jRDC2.zip and open it, but failed to understand.
Why jRDC.b4j needs to be compiled? What is the purpose of this file? Should then be uploaded to VPS?

This issue has been asked by @achtrade and I still found no answer about it.
Or, should we drop jRDC2 from our mind, if we program with B4A?
Meaning that I was already on the right track (see No.1) and better start programming,
rather than bothering on jRDC2, which is irrelevant to me? Thanks for any feedback.

Regards, Agus
 
Upvote 0

Agus Biyanto

New Member
Licensed User
Okay, i finally understand jRDC and jRDC2, both are running on my VPS.

However, I always try with simple example.
Now i want to test with your example, which you quoted very often in your writings.

Sub InsertRecord (Name As String)
Dim cmd As DBCommand = CreateCommand("insert_animal", Array(Name, Null))
Dim j AsHttpJob = CreateRequest.ExecuteBatch(Array(cmd), Null)
WaitFor(j) JobDone(j AsHttpJob)
If j.Success Then
Log("Inserted successfully!")
EndIf
j.Release
End Sub <--- where can I get the whole original source code for this example?

Is there any CRUD example for RDC other than this example? Thank you, Erel.

Rgds
 
Upvote 0
Top