JDBC Package and Driver Class
JDBC Package
Download the dws_8.1.x_jdbc_driver.zip package from the console.
For details, see Downloading the JDBC or ODBC Driver.
- 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).
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.See the reply and handling status in My Cloud VOC.
For any further questions, feel free to contact us through the chatbot.
Chatbot