Forum Discussion

tlena's avatar
tlena
New Contributor
6 years ago

"Error getting response; null" during actual JDBC request test step run with Salesforce DB

Hi,

I have successfully setup a salesforce db with ReadyApi by the following steps:

1. Add "sforce-jdbc.jar" to <installationFolder>\bin\ext

2. In Preferences>JDBC Drivers, add driver: "com.reliersoft.sforce.jdbc.Driver"

3. Value: jdbc:sforce://<link>?user=<user>&password=<password>

4. In Databases, add new connection and select the driver added in Step 1 (named it SFDB)

5. In the test case, add JDBC Request test step

6. In Configuration panel > Connection, select SFDB in the dropdown. Message pops up "Connection has changed, build Query?", select Yes.

Note: At this point, after clicking Yes, ReadyAPI pops up a message: "JdbcMetadataProvider: Failed to load metadata relations. null" then I just clicked OK

7. Build SQL Query window will open. Select any table and tick one column from the table, then click on "Test Query" button.

Result: Returns records and results from the table.

8. Click OK button.

9. Now back to JDBC Request Test Step, Test Connection -> "The Connection Successfully Tested" message pops up, click OK

10. Test the step by clicking play button "Submit request to specified database"

Expected Result: Results table from #7 will be returned

Actual Result: No data was returned. Request log message: "Error getting response; null"

Checked the logs and shows the following:

ERROR [errorlog] java.lang.NullPointerException
java.lang.NullPointerException: null
	at com.eviware.soapui.support.xml.XmlUtils.createColumn(XmlUtils.java:1463) ~[ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.support.jdbc.JdbcUtils.parseResultSet(JdbcUtils.java:198) ~[ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.support.jdbc.JdbcUtils.createResultSetHolder(JdbcUtils.java:167) ~[ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcResponse.<init>(JdbcResponse.java:47) ~[ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcSubmit.createResponse(JdbcSubmit.java:275) [ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcSubmit.runQuery(JdbcSubmit.java:178) [ready-api-soapui-2.6.0.jar:2.6.0]
	at com.eviware.soapui.impl.wsdl.panels.teststeps.JdbcSubmit.run(JdbcSubmit.java:150) [ready-api-soapui-2.6.0.jar:2.6.0]
	at java.util.concurrent.Executors$RunnableAdapter.call(Unknown Source) [?:1.8.0_181]
	at java.util.concurrent.FutureTask.run(Unknown Source) [?:1.8.0_181]
	at java.util.concurrent.ThreadPoolExecutor.runWorker(Unknown Source) [?:1.8.0_181]
	at java.util.concurrent.ThreadPoolExecutor$Worker.run(Unknown Source) [?:1.8.0_181]
	at java.lang.Thread.run(Unknown Source) [?:1.8.0_181]