No Suitable driver exception when I try to connect to postgres using the jdbc step in SoapUI (free version) - postgresql

I am sorry this question was asked many times.
Steps that I followed are as follows
downloaded the postgres jdbc driver from the following link
https://jdbc.postgresql.org/download.html
downloaded the latest version
Pasted the jar file in the soapui_home/bin/ext folder
Restarted SoapUI still getting the same error
I have added a jdbc step in SoapUI
Here is the driver, I have used PostgreSQL/org.postgresql.Driver
The string is dbc:postgresql://localhost:5432/databaseName?user=username&password=password
Environment
Redhat Linux
jdk version is 11
SoapUI version 5.7.0

Changed the driver string in the jdbc step to org.postgresql.Driver. It started working.

Related

DBeaver PostgreSQL Database - SCRAM authentication is not supported by this driver

I am trying to add a PostgreSQL database to DBeaver and am getting the following error when I try to connect to the database. I'm using DBeaver Version 7.2.3.202010191702. And after receiving this message I installed the latest version of the JDK (11.0.9) and pgJDBC (postgresql-42.2.18.jar). I've not had PostgreSQL on this machine yet, so it's a fresh install of the latest version (v13). Any suggestions?
SCRAM authentication is not supported by this driver. You need JDK >= 8 and pgjdbc >= 42.2.0 (not ".jre" vesions)
I had same error and in my situation I had old database drivers. These steps fixed it for me:
Go to Database Driver Manager
Select PostgreSQL (either double click or single select and then "Edit ...")
Click on "Download/Update"
Choose newer version (see bold version text) e.g. 42.2.18 for org.postgresql:postgresql:RELEASE
Press "Download"
Even using all the tips and tricks found on SO I was not able to connect to PGSQL 14 DBs.
I fixed it by using PostgreSQL (Old) driver, and it now works.
The problem I faced was identical, and what resolved it for me was:
Removing the previous PostgreSQL JDBC from the lib folder.
Downloading the latest PostgreSQL JDBC.
Substituting the old JDBC with the new one.
I had a problem similar to yours. This is the way to fix it:
open folder PostgreSQL\14\data, edit postgresql.config fix password_encryption to md5
alter all METHOD value to password in pg_hba.conf
restart postgres server
In my case, JRE version postgres being used in Pom.xml. Update it to the latest version and it should work

Cannot open the connection for the driver: org.eclipse.birt.report.data.oda.jdbc. using database postgres

I am working on report using BIRT with postgresql. While I am able to run the report successfully using BIRT viewer, when I try to integrate with tomcat, it gives the below error-
Cannot open the connection for the driver:
org.eclipse.birt.report.data.oda.jdbc.
org.eclipse.birt.report.data.oda.jdbc.JDBCException: Cannot load JDBC Driver class: org.postgresql.Driver.
while I have place the oda.jdbc.driver "postgresql-42.2.5" at location "\WEB-INF\lib" but still I'm facing this error.
I am running:
Birt version:-4.8.0
postgres version:- postgres9.5 (1.22.2)
After viewing error it seems the the JDBC driver jar is on at class path into BIRT runtime so it is not able to load the Driver and throwing error.
Please ensure the Driver jars are placed into libs directory of BIRT runtime installed in your server and it is available into class path at runtime.

Eclipse - MariaDB JDBC onnection issue (bug or I messed up something?)

I started learning Java EE, and I decided to develop my small application in simulated "real world production" environment:
I decoupled the development and deployment environment into a laptop (with Eclipse IDE) and a server (Raspberry Pi with Tomcat/TomEE and MariaDB).
With this environment I can learn not only EE development but the deployment phase, too.
The problem
After installation of MariaDB I realized that the MariaDB's JDBC connector doesn't work properly. I successfully made a connection in Eclipse via Generic JDBC (I used MariaDB's default connector). Pinging the server was also successful, but every query returned void results.
I tried the following queries:
show tables in dbName;
select * from tableName;
show databases;
When I tried to make entities from tables in a new JPA project, Eclipse didn't offered any tables.
Can somebody please help me to make a complete working connection to MariaDB.
What did I try (until this moment, without result)?
Updated the Raspbian system by apt-get update, moreover I did the same after installing MariaDB.
Tried to install MySql 5.6 with apt-get and dpkg, but the armhf version is not available on Raspbian Stretch
In Eclipse's Preferences/Data Management/Connectivity/Driver Definitions I tried to install MySql driver instead Generic JDBC
In properties (in Edit Driver Definition) tried the following Connection URL-s:
jdbc:mysql://hostName:port/
jdbc:mariadb://hostName:port/
jdbc:mysql://hostName:port/dbName
jdbc:mariadb://hostName:port/dbName
jdbc:mysql://hostName:port/dbName?user=userName&password=password
jdbc:mariadb://hostName:port/dbName?user=userName&password=password
Tried older version of JDBC connectors, too (mariadb-java-client-2.1.0.jar), without good result.
I installed MySQL on local machine, I could connect it in Eclipse successfully.
I could successfully connect, create, insert, alter tables in MariaDB from locally installed MySqlWorkbench.
I installed MariaDB on local machine. Despite the connection ping was successful in Eclipse, the void query result was the same as the remote MariaDB connection.
I installed NetBeans to check whether I can connect MariaDB with it's driver. The result was SUCCESS (screenshot is attached)
One more weird thing: in Data Source Explorer the tree structure is different between MySQL and MariaDB (see the screenshot)
The environment
Server:
Raspbian Stretch (Debian 9.1)
Java: openJKD 1.8.0_141, OpenJDK Runtime Environment build 1.8.0_141-8u141-b15-1~deb9ul-b15, OpenJDK Zero VM build 25.141-b15-1~deb9ul-b15
MariaDB Ver 15.1 Distrib 10.1.23-MariaDB, for debian-linux-gnueabihf (armv71)
Local machine:
Windows 10 Pro 64bit, version: 1703, build: 15063.674 (Hungarian language local)
MySqlWorkbench 6.3CE, 6.3.9 build 10690321 CE(64 bits)
Eclipse Neon.3 Release (4.6.3), Build id: 20170314-1500
NetBeans IDE 8.2, Build 201705191307
Java: JDK 1.8.0_151 (x86_64 architecture)
JDBC: mariadb-java-client-2.1.2.jar (This worked successfully with NetBeans)
To summarize, in Eclipse I can make a connection to MariaDB via Generic JDBC, the ping is successful, but I cannot get any result from queries (and cannot generate entities from tables).
Solved:
In Eclipse you don't have to use MariaDB's JDBC 2.1.2. connector. It is fully MySQL compatible just use MySQL JDBC 5.1 default (mysql-connector-java-5.1.41-bin.jar). Now it works fine!

Installing the DB2 9.7 ODBC driver

I have downloaded the DB2 ODBC client for Windows on x86, and found out that it's a .zip containing a tree of files. I found no instruction wheresoever on:
what to do with these files
how to subsequently register the ODBC driver.
Would anyone know?
This seems to be a common problem, as evidenced at How to install DB2 ODBC or OLEDB Driver where someone got the ZIP files but had no instructions on how to install them.
http://www.ryslander.com/how-to-install-and-configure-db2-odbc-driver/ has instructions with screenshots on how to install the driver, including registering it.

Ireport - JasperServer: PostgreSQL error (Driver)

I am trying to run my report created on iReport 4 on the jasperserver with a postgresql database (On my localhost).
The report runs perfect on the preview on iReport. Now when I upload it to the jasperServer I get the following error:
1 - org.postgresql.Driver
java.lang.Exception: 1 - org.postgresql.Driver 
at com.jaspersoft.ireport.jasperserver.ws.WSClient.runReport(WSClient.java:403) 
at com.jaspersoft.ireport.jasperserver.ws.WSClient.runReport(WSClient.java:320) 
at com.jaspersoft.ireport.jasperserver.ReportRunner.run(ReportRunner.java:70) 
at org.openide.util.RequestProcessor$Task.run(RequestProcessor.java:572) 
at org.openide.util.RequestProcessor$Processor.run(RequestProcessor.java:997)
Then I checked my OLAP settings on my jasperServer and noticed it doesn't have a postgresql driver.
mondrian.jdbcDrivers
sun.jdbc.odbc.JdbcOdbcDriver,org.hsqldb.jdbcDriver,oracle.jdbc.OracleDriver,com.mysql.jdbc.Driver
And on my jasperreport I use the following driver:
PostgreSQL (org.postgresql.Driver)
I think this is the problem. Does anyone know how I can add this postgresql driver to my jasperserver?
Or is there a different problem?
The PostgreSQL driver jar should go into the lib directory of your application server.
If you are using the bundled version of tomcat that comes with jasperServer, this will be
<jasperServer_install>\apache-tomcat\lib
More detailed instructions are available here.