Hi,
I am getting the following error
An error has occured in
sub:dbrequestmanager_ser_bytestoobject (java line: 290)
java.lang.NullPointerException
The Full error log is pasted below
Error reading response: (EOFException) java.io.EOFException
dbrequestmanager_ser_bytestoobject (java line: 290)
java.lang.NullPointerException
at com.myappname.dbrequestmanager._ser_bytestoobject(dbrequestmanager.java:290)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:169)
at anywheresoftware.b4a.BA$2.run(BA.java:328)
at android.os.Handler.handleCallback(Handler.java:733)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5001)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
at dalvik.system.NativeStart.main(Native Method)
java.lang.NullPointerException
The following line on the Sub ser_BytesToObject inside DbRequestManager.bas is causing the error.
res.Tag = m.Get("tag")
I am calling a Stored Procedure as given below with the parameters
call test_login('UserName','Password','e3ac950caee4d7e1',1)
Based on the parameters, the Stored procedure will validate the login and depending on the validation inside the stored procedure it may return 2 types of result.
ie
I am getting the run time error ONLY when the Login is successful, otherwise it is working fine as expected.
I tried to run the Stored Procedure from Heidi SQL to test the result when the login is successful. It is working fine and is returning all the columns as expected.
This the result that I get from the Stored Procedure on a Successful Login, unfortunately jRDC 2.1 errors out here without any proper clue of the error (at least for a person like me)
This code was perfectly working fine using jRDC ver 1. Two days back I tried changing to jRDC ver 2.1 and then the problem started.
I really don't understand why this is failing at dbrequestmanager_ser_bytestoobject and that too at the result tag.
I have included the latest DbRequestManager in the project
RandomAccessFile ver 2.20 is also included in my Project
Any help will be appreciated. I am stuck with this issue.
Regards
Anser
I am getting the following error
An error has occured in
sub:dbrequestmanager_ser_bytestoobject (java line: 290)
java.lang.NullPointerException
The Full error log is pasted below
Error reading response: (EOFException) java.io.EOFException
dbrequestmanager_ser_bytestoobject (java line: 290)
java.lang.NullPointerException
at com.myappname.dbrequestmanager._ser_bytestoobject(dbrequestmanager.java:290)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at anywheresoftware.b4a.BA.raiseEvent2(BA.java:169)
at anywheresoftware.b4a.BA$2.run(BA.java:328)
at android.os.Handler.handleCallback(Handler.java:733)
at android.os.Handler.dispatchMessage(Handler.java:95)
at android.os.Looper.loop(Looper.java:136)
at android.app.ActivityThread.main(ActivityThread.java:5001)
at java.lang.reflect.Method.invokeNative(Native Method)
at java.lang.reflect.Method.invoke(Method.java:515)
at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:785)
at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:601)
at dalvik.system.NativeStart.main(Native Method)
java.lang.NullPointerException
The following line on the Sub ser_BytesToObject inside DbRequestManager.bas is causing the error.
res.Tag = m.Get("tag")
I am calling a Stored Procedure as given below with the parameters
call test_login('UserName','Password','e3ac950caee4d7e1',1)
Based on the parameters, the Stored procedure will validate the login and depending on the validation inside the stored procedure it may return 2 types of result.
ie
- If not a valid user then, it will return a StatusID (Int) and a Msg (VarChar2). For eg, 1, "Invalid Login"
- If the login was successful it will return StatusID, Msg and few other details/columns pertaining to the successfully logged-in user.
I am getting the run time error ONLY when the Login is successful, otherwise it is working fine as expected.
I tried to run the Stored Procedure from Heidi SQL to test the result when the login is successful. It is working fine and is returning all the columns as expected.
This the result that I get from the Stored Procedure on a Successful Login, unfortunately jRDC 2.1 errors out here without any proper clue of the error (at least for a person like me)
This code was perfectly working fine using jRDC ver 1. Two days back I tried changing to jRDC ver 2.1 and then the problem started.
I really don't understand why this is failing at dbrequestmanager_ser_bytestoobject and that too at the result tag.
I have included the latest DbRequestManager in the project
RandomAccessFile ver 2.20 is also included in my Project
Any help will be appreciated. I am stuck with this issue.
Regards
Anser