B4J Library [class] jRDC - B4J implementation of RDC (Remote Database Connector)

Status
Not open for further replies.

incendio

Well-Known Member
Licensed User
Longtime User
I got error when trying to run it on Raspberry Pi2

Here is the error :
java.lang.RuntimeException: Cannot parse: null as boolean
at anywheresoftware.b4a.BA.parseBoolean(BA.java:273)
at anywheresoftware.b4a.BA.ObjectToBoolean(BA.java:342)
at b4j.example.rdcconnector._initialize(rdcconnector.java:90)
at b4j.example.main._appstart(main.java:46)
at sun.reflect.NativeMethodAccessorImpl.invoke0(Native Method)
at sun.reflect.NativeMethodAccessorImpl.invoke(NativeMethodAccesjava:57)

Jave ver on Raspberry is "1.7.0_40"
 

Roycefer

Well-Known Member
Licensed User
Longtime User
Check the RDConnector.Initialize method. It says you're trying to parse a Null as a Boolean, which it can't do.
 

incendio

Well-Known Member
Licensed User
Longtime User
Thanks for your replied.

Found the problem. It was in the config file. Missing the line Debug=true which is called in the Initialize method.
 

Bladimir Carrillo

Member
Licensed User
Longtime User
I tested my last app with jRDC (it's running perfectly with RDC) but have the following:
- ExecuteQuery (with SELECT) works well and return the correct results.
- ExecuteCommand (with INSERT or UPDATE) apparently successful execution returns (to jobDone Sub) but the database does not reflect changes.

May be a bug?
 

Bladimir Carrillo

Member
Licensed User
Longtime User
Are you 100% that the updates are not persisted? Try to create a new table and insert some data.
An exception will be thrown if the JDBC driver reports any error.
Yes Erel, when I stop jRDC and enable RDC again (with same configuration config.properties file) then works fine.
 

Bladimir Carrillo

Member
Licensed User
Longtime User
You will need to debug it. See which command is not working. RDC and jRDC are almost identical.

jRDC Debugging results:
Tests with oralce jdbc driver (ojdbc6.jar)

TEST 1

- Server runing on B4J ide / Debug(rapid) mode
- Client runing installed app
- Requests from client:
* SELECT. All OK
* UPDATE or INSERT. Connection to server crashes and any type of requests works (nor SELECT nor INSERT nor UPDATE), but continued running jRDC application on IDE. Any error is displayed on B4J ide.

TEST 2
- Server runing jRDC.jar
- Client runing on B4A ide / Debug(rapid) mode
- Requests from client:
* SELECT. All OK
* UPDATE or INSERT. "java.net.SocketTimeoutException" error on Job.ErrorMessage. Connection to server do not crashes and SELECT requests only works.
 
Status
Not open for further replies.
Cookies are required to use this site. You must accept them to continue using the site. Learn more…