JDBC Package and Driver Class
JDBC Package
Obtain the package dws_8.1.x_jdbc_driver.zip from the management console. For details, see Downloading Drivers.
- gsjdbc4.jar: Driver package compatible with PostgreSQL. The class name and class structure in the driver are the same as those in the PostgreSQL driver. All the applications running on PostgreSQL can be smoothly transferred to the current system.
- gsjdbc200.jar: This driver package is used when both PostgreSQL and GaussDB(DWS) are accessed in a JVM process. The main class name is com.huawei.gauss200.jdbc.Driver and the prefix of the URL for database connection is jdbc:gaussdb. Other information of this driver package is the same as that of gsjdbc4.jar.
Driver Class
Before creating a database connection, you need to load the database driver class org.postgresql.Driver (decompressed from gsjdbc4.jar) or com.huawei.gauss200.jdbc.Driver (decompressed from gsjdbc200.jar).
![](https://support.huaweicloud.com/eu/devg-dws/public_sys-resources/note_3.0-en-us.png)
GaussDB(DWS) is compatible with PostgreSQL in the use of JDBC. Therefore, when two JDBC drivers are used in the same process, class names may conflict.
Feedback
Was this page helpful?
Provide feedbackThank you very much for your feedback. We will continue working to improve the documentation.