https://notes.io/w3XVW
To carry out a lookup and open a connection to the database logically bound to the JNDI name, use the logical JNDI name. Doing this requires casting the lookup end result, which is in any other case a Java Object, to OracleDataSource and then using its getConnection method to open the connection. Creating and registering data sources is usually dealt with by a JNDI administrator, not in a JDBC utility. Using JNDI performance requires the jndi.jar file to be within the CLASSPATH environment variable. This file is included with the Java products on the set up CD. A