First we need to know to which DBMS we want to connect.
You can find all the supported driver in the JDBC Driver List page of the SoapUI website.
Take note of the Driver name, i.e. oracle.jdbc.driver.OracleDriver and download the .jar file.
Put the jar file in the ext directory, it should be in ithe same folder as the SoapUI start script.
In Linux, you can find it in this way:
$~ which SoapUI-5.2.1
/usr/local/bin/SoapUI-5.2.1
$~ ls -l /usr/local/bin/SoapUI-5.2.1
lrwxrwxrwx 1 root root 44 feb 9 15:40 /usr/local/bin/SoapUI-5.2.1 -> /opt/SmartBear/SoapUI-5.2.1/bin/SoapUI-5.2.1
$~ cd /opt/SmartBear/SoapUI-5.2.1/bin
$bin ls -l
...
drwxr-xr-x 2 root root 4096 feb 29 17:50 ext
...
- Create a JDBC Request Test Step in a Test Case;
- set the driver name in the
Driverfield, i.e.oracle.jdbc.driver.OracleDriver; - set the Connection String, i.e.
jdbc:oracle:thin:user/password@//host.or.ip.address:1521/SID; - click on the
TestConnectionbutton to test the connection.
Now you can use the SQL Query to get values or verify them.
Enjoy
Great tip, thank you