You can do this using one of the following ways:įrom the main menu, navigate to File | New | Data Source and select Oracle. To connect to the database, create a data source that will store your connection details. Otherwise, you will receive an error that the native library cannot be loaded. For example, if you use the Oracle driver 19.8.0.0, the instant client must be of the same version. Versions of the driver and the instant client must be the same. In the file browser, navigate to the directory of the Instant Client created previously (for example, ~/Oracle/instantclient_19_8) and click Open. In the Driver Files pane, click the Add icon ( ) and select Native Library Path…. In the list of drivers, right-click the Oracle driver and select Duplicate.Ĭhange the name of the duplicated Oracle driver (for example, Oracle ). In the Data Sources and Drivers dialog, click the Drivers tab. In the Database Explorer Alt+1 ( View | Tool Windows | Database Explorer), click the Data Source Properties icon ( ). You can open data source properties by using one of the following options: Environment variables will work only for the current session in the command prompt.Ĭreating the Oracle OCI connection Step 1. Sqlplus previous commands work in the command prompt only if you set environment variables. So, the JDBC driver must have the same version as the Oracle server. And this native library is a part of Oracle server software. When the Oracle Instant Client is installed on the machine with the Oracle server, the JDBC driver uses the native library to connect to the Oracle server. But if we switch to Oracle driver 19.8.0.0, the connection will be successful. If we use the Oracle driver 19.3.0.0, we are going to get Incompatible version of libocijdbc. Oracle Database 12c Enterprise Edition Release 12.2.0.1.0 - 64bit Production Otherwise, you will see errors like Native library cannot be loaded or Incompatible version of libocijdbc.įor example, consider the following Oracle setup: But the JDBC driver must have the same version as the Oracle Instant Client. For example, Oracle Client 19.x can successfully connect to Oracle server 11.2. When the Oracle Instant Client is installed on a separate machine, versions of the Oracle Instant Client and Oracle Server may differ. Running Oracle instance with access permissions for your user.Ĭompatibility of versions in OCI mode Installation on separate machines Download packages for your operating system from the Oracle Instant Client Downloads page at. Oracle Instant Client (OCI) packages: Basic Package, SQL*Plus Package, JDBC Supplement Package. In this case, the JDBC driver's version must be the same as the version of these native libraries. In OCI mode, the JDBC driver uses native libraries. In this mode, various versions of the JDBC driver can be used. In thin mode, the JDBC driver always connects to the TNS listener. To download Oracle database software, refer to the official software downloads.įor more versions of Oracle JDBC driver, refer to the official JDBC driver downloads.ĭataGrip uses JDBC drivers to connect to the Oracle server through the TNS protocol. For full information about Oracle, refer to the official documentation.
0 Comments
Leave a Reply. |
AuthorWrite something about yourself. No need to be fancy, just an overview. ArchivesCategories |