I thought that in Linux, ODBC data sources should be created in the same way as in windows. In fact, it is not necessary at all. You can directly connect to Oracle using the JAVA JDBC driver.
I thought that in Linux, ODBC data sources should be created in the same way as in windows. In fact, it is not necessary at all. You can directly connect to Oracle using the JAVA JDBC driver.
I thought that in Linux, ODBC data sources should be created in the same way as in windows. In fact, it is not necessary at all. You can directly connect to Oracle using the JAVA JDBC driver.
Use the following statement to load the JDBC driver of Oracle: Class. forName ("Oracle. driver. OracleDriver ");
Url = "jdbc: Oracle: thin: @ localhost: 1521: lg"; lg: Oracle_SID.
The key is to set the CLASSPATH variable: Oracle comes with a JDBC driver package. In the $ Oracle_HOME/jdbc/directory, there is a package named classes12.jar, so: export CLASSPATH = $ JAVA_HOME/lib: $ Oracle_HOME/jdbc/classes12.jar
The preceding settings allow you to successfully connect to the Oracle database.
The key is the driver problem. Remember to start the 1521 port listener ($ lsnrctl start ).