I have a Java code to call two MATLAB jobs. The first job is to set the java class path by using javaaddpath to include the jdbc driver jar. The second job is to read data from database. The first job is executed successfully. But the second job can't pick up the class path that the first job sets. If I print out java classpath using javaclasspath('-all'), the jdbc driver jar is not there. Can the javaaddpath setting cross the global java jobs?
I'm using MATLAB AND MCR 2012a. Thanks!