OceanBase Connector/J uses the standard Java Database Connectivity (JDBC) APIs for Java applications to connect to OBServers.
Java Database Connectivity (JDBC) is a Java standard that provides an API for connecting Java programs to a relational database. The JDBC standard was defined by Sun Microsystems and is implemented by the standard java.sql API. Providers can implement and extend it by using their own JDBC drivers. JDBC is a Call Level Interface (CLI) based on X/Open SQL.
OceanBase Connector/J is a JDBC Type 4 driver that can be connected to a database engine by using local protocols. OceanBase Connector/J is compatible with the OB2.0 protocol.
OBServers support OceanBase Connector/J and are fully compatible with MySQL Connector Java, which is the native JDBC driver for MySQL. OceanBase Connector/J is fully compatible with MySQL JDBC. OceanBase Connector/J automatically determines whether OceanBase Database runs in MySQL or Oracle mode and supports both modes at the protocol layer.
Notice
An OBServer determines whether OceanBase Database runs in MySQL or Oracle mode based on the tenant name that is used when the driver is connected to the database service. Tenants in Oracle mode can use only Oracle-compatible SQL syntax.
OceanBase Connector/J is compatible with standard JDBC APIs and Oracle Driver. OBServers in Oracle mode are compatible with most Oracle syntax.
OceanBase Connector/J can be installed with one click. The installation package is named oceanbase-client-[Version No.].jar. You have obtained the installation package of the OceanBase Connector/J driver from OceanBase Technical Support. For more information about the installation procedure, see OceanBase Connector/J.